You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(readme): update features and error handling sections
Added real-time progress notifications and improved error handling documentation:
- Added new features for progress notifications and SCM integration
- Updated usage steps to include progress monitoring
- Expanded error handling section with detailed descriptions
- Added error resolution guidance for each error type
- Reorganised error table with clearer categories and descriptions
- Updated command documentation to mention progress notifications
Copy file name to clipboardExpand all lines: README.md
+30-24Lines changed: 30 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,8 @@ The generated commit messages are compatible with [googleapis/release-please](ht
37
37
- Preview and edit generated commit messages before applying the commit
38
38
- Uses markdown formatting for commit messages
39
39
- Implements conventional commit format with type, scope, subject, and body
40
+
- Real-time progress notifications during commit message generation
41
+
- Seamless integration with VSCode's Source Control Management (SCM)
40
42
41
43
## Requirements
42
44
@@ -56,16 +58,20 @@ Install the extension directly from the [Visual Studio Code Marketplace](https:/
56
58
57
59
1. Stage the changes that you wish to commit as normal
58
60
2. Run the command: "DiffCommit: Generate Commit Message" (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> → <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>)
59
-
3. Confirm or edit the generated commit message in the Source Control message input
60
-
4. Click 'Commit' to commit the changes with the generated message
61
+
3. Monitor progress in the notification area as the extension:
62
+
- Retrieves the git diff
63
+
- Validates your API key
64
+
- Generates the commit message
65
+
4. Review the generated message in the Source Control message input
66
+
5. Click 'Commit' to commit the changes with the generated message
61
67
62
68
## Commands
63
69
64
70
DiffCommit commands can be accessed from the Command Palette (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd>) or using the default keyboard shortcuts.
65
71
66
72
### `DiffCommit: Generate Commit Message`
67
73
68
-
This will generate a commit message for staged changes and enter it in the Source Control message input box. You can preview and edit the generated message before committing.
74
+
This will generate a commit message for staged changes and enter it in the Source Control message input box. You can preview and edit the generated message before committing. Progress is shown through notifications as the extension works.
@@ -150,27 +156,27 @@ For concise, focused commit messages, I recommend the default value of 0.3. If y
150
156
151
157
## Error Handling
152
158
153
-
Diff Commit accommodates error handling to provide clear feedback and assist in troubleshooting. The following are the common warning or error scenarios you might encounter.
|**Git Related**| Git extension not found in VSCode ||
158
-
|| No Git repository found in the current workspace ||
159
-
|| No workspace folder found ||
160
-
|| No staged changes detected ||
161
-
|**API Key Related**| API key is missing or not provided ||
162
-
|| Invalid API key format (should start with sk-ant-api) ||
163
-
|| Failed to access or update secure storage ||
164
-
|**Anthropic API Errors**| Bad Request: Review your prompt and try again |400 |
165
-
|| Unauthorized: Invalid API key, update your API key and try again |401 |
166
-
|| Forbidden: Permission denied, update your API key and try again | 403 |
167
-
|| Rate Limited: Too many requests, try again later |429 |
168
-
|| Server Error: Anthropic API server error |500 |
169
-
|**Other Errors**| Failed to write commit message to Source Control ||
170
-
|| Failed to open commit message preview ||
171
-
|| No commit message was generated by the API ||
172
-
173
-
If you encounter any of these errors, Diff Commit will display a message with more details. For persistent issues, please check your configuration and if appropriate, raise an issue on [GitHub](https://github.com/tsdevau/diff-commit/issues).
159
+
Diff Commit provides clear feedback for various scenarios to help troubleshoot issues. Here are the common messages you might encounter:
|**Git Related**| Git extension not found in VSCode |VSCode's Git extension is not installed or enabled|
164
+
|| No Git repository found in the current workspace |The current workspace is not a Git repository |
165
+
|| No workspace folder found |No workspace is open in VSCode |
166
+
|| No changes detected | No staged changes found to generate a commit message for|
167
+
|**API Key Related**| API key is missing or not provided |No API key has been set |
168
+
|| Invalid API key format (should start with sk-ant-api) |The provided API key doesn't match the expected format|
169
+
|| Failed to access or update secure storage |Unable to store or retrieve the API key from secure storage|
170
+
|**Anthropic API Errors**| Bad Request: Review your prompt and try again |Invalid request to the Anthropic API (400) |
171
+
|| Unauthorized: Invalid API key, update your API key and try again |The API key is invalid or expired (401) |
172
+
|| Forbidden: Permission denied, update your API key and try again |The API key doesn't have permission for this operation (403)|
173
+
|| Rate Limited: Too many requests, try again later |You've exceeded your API rate limit (429) |
174
+
|| Server Error: Anthropic API server error |An error occurred on Anthropic's servers (500) |
175
+
|**Other Errors**| Failed to write commit message to Source Control |Unable to update the SCM input box with the generated message|
176
+
|| Failed to open commit message preview |Unable to open the preview editor |
177
+
|| No commit message was generated by the API |The API response didn't contain a valid commit message|
178
+
179
+
Each error includes specific guidance on how to resolve the issue. For persistent problems, please check your configuration and if appropriate, raise an issue on [GitHub](https://github.com/tsdevau/diff-commit/issues).
0 commit comments