Skip to content

Commit 3fb5c28

Browse files
committed
📝 Update docs with code review feature details
Update documentation to include the new AI-powered code review functionality This update adds comprehensive documentation for the recently added code review feature, while also refreshing existing docs: - Add new code-review-docs.md with usage instructions and best practices - Add new changelog-release-notes-docs.md with detailed documentation - Update CONFIG.md with instruction preset and review-related options - Update README.md to highlight the new code review functionality - Update usage-guide.md with code review commands and examples These changes ensure users can take full advantage of the code review capabilities introduced in the previous commit.
1 parent 76bdf31 commit 3fb5c28

File tree

5 files changed

+647
-25
lines changed

5 files changed

+647
-25
lines changed

CONFIG.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,22 @@ The configuration file is organized into these main sections:
1515
### Global Settings
1616

1717
- `use_gitmoji`: Boolean (optional)
18+
1819
- Description: Enables Gitmoji in commit messages.
1920
- Default: `false`
2021
- Example: `use_gitmoji = true`
2122

2223
- `custom_instructions`: String (optional)
23-
- Description: Custom instructions included in all LLM prompts.
24+
25+
- Description: Custom instructions included in all LLM prompts for commit messages, code reviews, changelogs, and release notes.
2426
- Default: `""`
2527
- Example: `custom_instructions = "Always mention the ticket number and focus on the impact of changes."`
2628

29+
- `instruction_preset`: String (optional)
30+
- Description: Default preset for AI instructions.
31+
- Default: `"default"`
32+
- Example: `instruction_preset = "conventional"`
33+
2734
### Default Provider
2835

2936
- `default_provider`: String (required)
@@ -36,15 +43,18 @@ The configuration file is organized into these main sections:
3643
Each provider has its own subtable under `[providers]` with these fields:
3744

3845
- `api_key`: String (required)
46+
3947
- Description: The provider's API key.
4048
- Example: `api_key = "sk-1234567890abcdef"`
4149

4250
- `model`: String (optional)
51+
4352
- Description: The specific model to use.
4453
- Default: Provider-dependent
4554
- Example: `model = "gpt-4o"`
4655

4756
- `additional_params`: Table (optional)
57+
4858
- Description: Additional provider or model-specific parameters.
4959
- Example: `additional_params = { temperature = "0.7", max_tokens = "150" }`
5060

@@ -69,6 +79,7 @@ Always mention the ticket number if applicable.
6979
Focus on the impact of changes rather than implementation details.
7080
"""
7181
default_provider = "openai"
82+
instruction_preset = "conventional"
7283

7384
[providers.openai]
7485
api_key = "sk-1234567890abcdef"
@@ -94,6 +105,7 @@ git-iris config --provider openai --param temperature=0.7 --param max_tokens=150
94105
git-iris config --gitmoji true
95106
git-iris config --custom-instructions "Your custom instructions here"
96107
git-iris config --token-limit 8000
108+
git-iris config --preset conventional
97109
```
98110

99111
You can also edit the `~/.config/git-iris/config.toml` file directly with a text editor.
@@ -136,5 +148,6 @@ If you encounter issues:
136148
2. Check that you're using supported models for each provider.
137149
3. Ensure your custom instructions don't exceed token limits.
138150
4. Review the Git-Iris logs for any error messages.
151+
5. For code review or changelog generation issues, try using a higher token limit.
139152

140-
For further assistance, please refer to the [Git-Iris documentation](https://github.com/hyperb1iss/git-iris/wiki) or [open an issue](https://github.com/hyperb1iss/git-iris/issues) on the GitHub repository.
153+
For further assistance, please refer to the [Git-Iris documentation](https://github.com/hyperb1iss/git-iris/wiki) or [open an issue](https://github.com/hyperb1iss/git-iris/issues) on the GitHub repository.

README.md

Lines changed: 57 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@
22

33
<div align="center">
44

5-
[![CI/CD](https://github.com/hyperb1iss/git-iris/actions/workflows/cicd.yml/badge.svg)](https://github.com/hyperb1iss/git-iris/actions)
6-
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
7-
[![GitHub Release][releases-shield]][releases]
5+
[![CI/CD](https://img.shields.io/github/actions/workflow/status/hyperb1iss/git-iris/cicd.yml?style=for-the-badge&logo=github-actions&logoColor=white&color=4C566A)](https://github.com/hyperb1iss/git-iris/actions)
6+
[![License](https://img.shields.io/badge/License-Apache%202.0-5E81AC?style=for-the-badge&logo=apache&logoColor=white&color=3B6EA8)](https://opensource.org/licenses/Apache-2.0)
7+
[![GitHub Release](https://img.shields.io/github/release/hyperb1iss/git-iris.svg?style=for-the-badge&logo=github&logoColor=white&color=9D6DB3)][releases]
8+
[![Crates.io](https://img.shields.io/crates/v/git-iris.svg?style=for-the-badge&logo=rust&logoColor=white&color=D35D47)][crates]
9+
[![Rust](https://img.shields.io/badge/rust-stable-EBCB8B?style=for-the-badge&logo=rust&logoColor=white&color=EFBB4D)](https://www.rust-lang.org/)
10+
[![ko-fi](https://img.shields.io/badge/Ko--fi-Support%20Me-A3BE8C?style=for-the-badge&logo=ko-fi&logoColor=white&color=82B062)](https://ko-fi.com/hyperb1iss)
811

9-
*Elevate your Git workflow with the power of AI* 🚀
12+
_Elevate your Git workflow with the power of AI_ 🚀
1013

1114
[Installation](#installation)[Configuration](#configuration)[Usage](#usage)[Contributing](#contributing)[License](#license)
1215

@@ -18,17 +21,18 @@
1821
<img src="https://raw.githubusercontent.com/hyperb1iss/git-iris/main/docs/images/git-iris-screenshot-3.png" alt="Git-Iris Screenshot 3" width="33%">
1922
</div>
2023

21-
*Git-Iris in action: AI-powered Git workflow assistance*
24+
_Git-Iris in action: AI-powered Git workflow assistance_
2225

2326
## 🌟 Overview
2427

25-
Git-Iris is a comprehensive AI-powered Git workflow assistant that enhances your development process from start to finish. It offers intelligent support for crafting meaningful commit messages, generating insightful changelogs, and creating detailed release notes. By leveraging advanced AI models, Git-Iris boosts your productivity and improves the quality of your project documentation.
28+
Git-Iris is a comprehensive AI-powered Git workflow assistant that enhances your development process from start to finish. It offers intelligent support for crafting meaningful commit messages, generating insightful changelogs, creating detailed release notes, and providing code reviews. By leveraging advanced AI models, Git-Iris boosts your productivity and improves the quality of your project documentation.
2629

2730
## ✨ Features
2831

2932
Git-Iris offers a suite of AI-powered tools to enhance your Git workflow:
3033

3134
- 🤖 **Intelligent Commit Messages**: Generate context-aware, meaningful commit messages
35+
- 🔍 **AI-Powered Code Reviews**: Get detailed feedback on your changes before committing
3236
- 📜 **Dynamic Changelog Generation**: Create structured, detailed changelogs between any two Git references
3337
- 📋 **Comprehensive Release Notes**: Automatically generate release notes with summaries and key changes
3438
- 🔄 **Multi-Provider AI Support**: Leverage OpenAI GPT-4o, Anthropic Claude, or Ollama for AI capabilities
@@ -58,6 +62,7 @@ cargo install git-iris
5862
### Manual Installation
5963

6064
1. Clone the repository:
65+
6166
```bash
6267
git clone https://github.com/hyperb1iss/git-iris.git
6368
cd git-iris
@@ -120,6 +125,7 @@ git-iris gen
120125
```
121126

122127
Options:
128+
123129
- `-a`, `--auto-commit`: Automatically commit with the generated message
124130
- `-i`, `--instructions`: Provide custom instructions for this commit
125131
- `--provider`: Specify an LLM provider (openai, claude, ollama)
@@ -130,6 +136,7 @@ Options:
130136
- `--no-verify`: Skip verification steps (pre/post commit hooks)
131137

132138
Example:
139+
133140
```bash
134141
git-iris gen -a -i "Focus on performance improvements" --provider claude --preset detailed
135142
```
@@ -154,6 +161,37 @@ The interactive CLI allows you to refine and perfect your commit messages:
154161
- Press Enter to commit
155162
- Press Esc to cancel
156163

164+
### Getting an AI Code Review
165+
166+
Git-Iris can analyze your staged changes and provide a detailed code review:
167+
168+
```bash
169+
git-iris review
170+
```
171+
172+
The review includes:
173+
174+
- A summary of the changes
175+
- Code quality assessment
176+
- Suggestions for improvement
177+
- Identified issues
178+
- Positive aspects of your code
179+
180+
Options:
181+
182+
- `-i`, `--instructions`: Provide custom instructions for this review
183+
- `--provider`: Specify an LLM provider (openai, claude, ollama)
184+
- `--preset`: Use a specific instruction preset
185+
- `-p`, `--print`: Print the generated review to stdout and exit
186+
187+
Example:
188+
189+
```bash
190+
git-iris review -i "Pay special attention to error handling" --provider claude
191+
```
192+
193+
This allows you to get valuable feedback on your code before committing it, improving code quality and catching potential issues early.
194+
157195
### Generating a Changelog
158196

159197
Git-Iris can generate changelogs between two Git references:
@@ -163,6 +201,7 @@ git-iris changelog --from <from-ref> --to <to-ref>
163201
```
164202

165203
Options:
204+
166205
- `--from`: Starting Git reference (commit hash, tag, or branch name)
167206
- `--to`: Ending Git reference (defaults to HEAD if not specified)
168207
- `--instructions`: Custom instructions for changelog generation
@@ -171,6 +210,7 @@ Options:
171210
- `--gitmoji`: Enable or disable Gitmoji in the changelog
172211

173212
Example:
213+
174214
```bash
175215
git-iris changelog --from v1.0.0 --to v1.1.0 --detail-level detailed --gitmoji true
176216
```
@@ -186,6 +226,7 @@ git-iris release-notes --from <from-ref> --to <to-ref>
186226
```
187227

188228
Options:
229+
189230
- `--from`: Starting Git reference (commit hash, tag, or branch name)
190231
- `--to`: Ending Git reference (defaults to HEAD if not specified)
191232
- `--instructions`: Custom instructions for release notes generation
@@ -194,6 +235,7 @@ Options:
194235
- `--gitmoji`: Enable or disable Gitmoji in the release notes
195236

196237
Example:
238+
197239
```bash
198240
git-iris release-notes --from v1.0.0 --to v1.1.0 --preset conventional --detail-level standard
199241
```
@@ -244,11 +286,13 @@ Presets work seamlessly with other Git-Iris features. For example, if you have G
244286
Custom instructions allow you to provide specific guidance for commit message generation. These can be set globally or per-commit.
245287

246288
Setting global custom instructions:
289+
247290
```bash
248291
git-iris config --instructions "Always include the ticket number and mention performance impacts"
249292
```
250293

251294
Providing per-commit instructions:
295+
252296
```bash
253297
git-iris gen -i "Emphasize security implications of this change"
254298
```
@@ -274,21 +318,25 @@ This will use the 'detailed' preset instead of your default, along with the cust
274318
### Examples of Custom Instructions
275319

276320
1. **Ticket Number Integration**
321+
277322
```
278323
Always start the commit message with the JIRA ticket number in square brackets
279324
```
280325

281326
2. **Language-Specific Conventions**
327+
282328
```
283329
For Rust files, mention any changes to public APIs or use of unsafe code
284330
```
285331

286332
3. **Team-Specific Guidelines**
333+
287334
```
288335
Follow the Angular commit message format: <type>(<scope>): <subject>
289336
```
290337

291338
4. **Project-Specific Context**
339+
292340
```
293341
For the authentication module, always mention if there are changes to the user model or permissions
294342
```
@@ -316,13 +364,6 @@ Distributed under the Apache 2.0 License. See `LICENSE` for more information.
316364

317365
</div>
318366

319-
## 💖 Acknowledgements
320-
321-
- [OpenAI](https://openai.com/) and [Anthropic](https://www.anthropic.com/) for their cutting-edge language models
322-
- The Rust community for the robust ecosystem and tooling
323-
324-
---
325-
326367
<div align="center">
327368

328369
Created by [Stefanie Jane 🌠](https://github.com/hyperb1iss)
@@ -331,8 +372,8 @@ If you find Git-Iris useful, [buy me a Monster Ultra Violet](https://ko-fi.com/h
331372

332373
</div>
333374

334-
[crates-shield]: https://img.shields.io/crates/v/git-iris.svg
375+
[crates-shield]: https://img.shields.io/crates/v/git-iris.svg?style=for-the-badge&logo=rust&logoColor=white&color=D35D47
335376
[crates]: https://crates.io/crates/git-iris
336-
[releases-shield]: https://img.shields.io/github/release/hyperb1iss/git-iris.svg
377+
[releases-shield]: https://img.shields.io/github/release/hyperb1iss/git-iris.svg?style=for-the-badge&logo=github&logoColor=white&color=9D6DB3
337378
[releases]: https://github.com/hyperb1iss/git-iris/releases
338-
[license-shield]: https://img.shields.io/github/license/hyperb1iss/git-iris.svg
379+
[license-shield]: https://img.shields.io/github/license/hyperb1iss/git-iris.svg?style=for-the-badge&logo=apache&logoColor=white&color=3B6EA8

0 commit comments

Comments
 (0)