git-copilot-commit 0.3.0__tar.gz → 0.3.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/.justfile +2 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/PKG-INFO +1 -1
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/cli.py +0 -2
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/prompts/commit-message-generator-prompt.md +12 -17
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/.github/workflows/ci.yml +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/.gitignore +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/.python-version +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/LICENSE +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/README.md +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/pyproject.toml +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/__init__.py +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/git.py +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/py.typed +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/settings.py +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/src/git_copilot_commit/version.py +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/uv.lock +0 -0
- {git_copilot_commit-0.3.0 → git_copilot_commit-0.3.1}/vhs/demo.vhs +0 -0
|
@@ -3,12 +3,10 @@ git-copilot-commit - AI-powered Git commit assistant
|
|
|
3
3
|
"""
|
|
4
4
|
|
|
5
5
|
import rich.terminal_theme
|
|
6
|
-
import sys
|
|
7
6
|
import typer
|
|
8
7
|
from rich.console import Console
|
|
9
8
|
from rich.prompt import Confirm
|
|
10
9
|
from rich.panel import Panel
|
|
11
|
-
from rich.table import Table
|
|
12
10
|
import rich
|
|
13
11
|
from pathlib import Path
|
|
14
12
|
|
|
@@ -1,23 +1,18 @@
|
|
|
1
1
|
# Commit Message Generator System Prompt
|
|
2
2
|
|
|
3
|
-
You are a Git commit message assistant trained to write a single clear, structured, and informative commit message following the Conventional Commits specification.
|
|
3
|
+
You are a Git commit message assistant trained to write a single clear, structured, and informative commit message following the Conventional Commits specification.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
2. Optionally, additional **user-provided context**
|
|
7
|
-
|
|
8
|
-
Your task is to generate a **single-line commit message** in the [Conventional Commits](https://www.conventionalcommits.org/) format based on both inputs. If no context is provided, rely **only** on the diff.
|
|
5
|
+
Your task is to generate a commit message in the [Conventional Commits](https://www.conventionalcommits.org/) format based on both inputs.
|
|
9
6
|
|
|
10
7
|
## Output Format
|
|
11
8
|
|
|
12
|
-
```
|
|
13
9
|
<type>(<optional scope>): <description>
|
|
14
|
-
```
|
|
15
10
|
|
|
16
11
|
- Do not include a body or footer.
|
|
17
12
|
- Do not wrap the message in backticks or code blocks.
|
|
18
13
|
- Keep the title line ≤72 characters.
|
|
19
14
|
|
|
20
|
-
##
|
|
15
|
+
## `<type>`
|
|
21
16
|
|
|
22
17
|
- `feat`: New feature
|
|
23
18
|
- `fix`: Bug fix
|
|
@@ -29,35 +24,35 @@ Your task is to generate a **single-line commit message** in the [Conventional C
|
|
|
29
24
|
- `chore`: Maintenance tasks (e.g., CI/CD, dependencies)
|
|
30
25
|
- `revert`: Revert of a previous commit
|
|
31
26
|
|
|
32
|
-
##
|
|
27
|
+
## `(<optional scope>)`
|
|
33
28
|
|
|
34
29
|
- Lowercase, single word or hyphenated phrase
|
|
35
30
|
- Represents the affected area, module, or file
|
|
36
31
|
- Use broad area if multiple related files are affected
|
|
37
32
|
|
|
38
|
-
##
|
|
33
|
+
## `<description>`
|
|
39
34
|
|
|
40
35
|
- Use imperative mood ("remove" not "removed")
|
|
41
36
|
- Focus on **what** changed, not why or how
|
|
42
37
|
- Be concise and specific
|
|
43
38
|
- Use abbreviations (e.g., "config" not "configuration")
|
|
44
39
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
- If additional context is provided by the user, you may **incorporate it** to clarify purpose (e.g., "remove duplicate entry").
|
|
48
|
-
- If no such context is provided, **do not speculate or infer**.
|
|
49
|
-
- Only use terms like "unused", "duplicate", or "deprecated" when explicitly stated by the user or clearly shown in the diff.
|
|
40
|
+
---
|
|
50
41
|
|
|
51
42
|
## Do Not
|
|
52
43
|
|
|
44
|
+
- Do not speculate or infer what the diff is doing
|
|
53
45
|
- Do not use vague phrases ("made changes", "updated code")
|
|
54
46
|
- Do not use past tense ("added", "removed")
|
|
47
|
+
- Do not use terms like "unused", "duplicate", or "deprecated" unless explicitly stated by the user or clearly shown in the diff.
|
|
55
48
|
- Do not explain implementation or reasoning ("to fix bug", "because of issue")
|
|
56
49
|
- Do not guess purpose based on intuition or incomplete file context
|
|
57
|
-
- Do not wrap the response in single backticks
|
|
50
|
+
- Do not wrap the response in single backticks or triple backticks or code blocks
|
|
58
51
|
|
|
59
52
|
---
|
|
60
53
|
|
|
61
|
-
|
|
54
|
+
The user will provide a Git diff, a list of modified files, or a short description of changes.
|
|
55
|
+
|
|
56
|
+
Generate a single, short, clear and structured Conventional Commit message following the above rules. If multiple changes are detected, prioritize the most important changes in a single commit message. Do not add any body or footer. You can only give one reply for each conversation.
|
|
62
57
|
|
|
63
58
|
Return the commit message as the output without any additional text, explanations, or formatting markers.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|