codexspec 0.3.1__tar.gz → 0.3.2__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.
Files changed (36) hide show
  1. {codexspec-0.3.1 → codexspec-0.3.2}/PKG-INFO +8 -1
  2. {codexspec-0.3.1 → codexspec-0.3.2}/README.md +7 -0
  3. {codexspec-0.3.1 → codexspec-0.3.2}/pyproject.toml +1 -1
  4. codexspec-0.3.2/templates/commands/commit-staged.md +31 -0
  5. codexspec-0.3.2/templates/commands/commit.md +70 -0
  6. {codexspec-0.3.1 → codexspec-0.3.2}/.gitignore +0 -0
  7. {codexspec-0.3.1 → codexspec-0.3.2}/LICENSE +0 -0
  8. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/bash/check-prerequisites.sh +0 -0
  9. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/bash/common.sh +0 -0
  10. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/bash/create-new-feature.sh +0 -0
  11. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/powershell/check-prerequisites.ps1 +0 -0
  12. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/powershell/common.ps1 +0 -0
  13. {codexspec-0.3.1 → codexspec-0.3.2}/scripts/powershell/create-new-feature.ps1 +0 -0
  14. {codexspec-0.3.1 → codexspec-0.3.2}/src/codexspec/__init__.py +0 -0
  15. {codexspec-0.3.1 → codexspec-0.3.2}/src/codexspec/i18n.py +0 -0
  16. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/analyze.md +0 -0
  17. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/checklist.md +0 -0
  18. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/clarify.md +0 -0
  19. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/constitution.md +0 -0
  20. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/generate-spec.md +0 -0
  21. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/implement-tasks.md +0 -0
  22. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/plan-to-tasks.md +0 -0
  23. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/review-plan.md +0 -0
  24. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/review-spec.md +0 -0
  25. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/review-tasks.md +0 -0
  26. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/spec-to-plan.md +0 -0
  27. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/specify.md +0 -0
  28. {codexspec-0.3.1 → codexspec-0.3.2}/templates/commands/tasks-to-issues.md +0 -0
  29. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/checklist-template.md +0 -0
  30. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/constitution-template.md +0 -0
  31. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/plan-template-detailed.md +0 -0
  32. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/plan-template-simple.md +0 -0
  33. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/spec-template-detailed.md +0 -0
  34. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/spec-template-simple.md +0 -0
  35. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/tasks-template-detailed.md +0 -0
  36. {codexspec-0.3.1 → codexspec-0.3.2}/templates/docs/tasks-template-simple.md +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: codexspec
3
- Version: 0.3.1
3
+ Version: 0.3.2
4
4
  Summary: CodexSpec - A Spec-Driven Development (SDD) toolkit for Claude Code
5
5
  Project-URL: Homepage, https://github.com/Zts0hg/codexspec
6
6
  Project-URL: Repository, https://github.com/Zts0hg/codexspec
@@ -398,6 +398,13 @@ After initialization, these slash commands are available in Claude Code:
398
398
  | `/codexspec.checklist` | Generate quality checklists for requirements validation |
399
399
  | `/codexspec.tasks-to-issues` | Convert tasks to GitHub issues for project management integration |
400
400
 
401
+ #### Git Workflow Commands
402
+
403
+ | Command | Description |
404
+ |---------|-------------|
405
+ | `/codexspec.commit` | Generate Conventional Commits messages based on git status and session context |
406
+ | `/codexspec.commit-staged` | Generate commit message from staged changes only |
407
+
401
408
  ## Workflow Overview
402
409
 
403
410
  ```
@@ -360,6 +360,13 @@ After initialization, these slash commands are available in Claude Code:
360
360
  | `/codexspec.checklist` | Generate quality checklists for requirements validation |
361
361
  | `/codexspec.tasks-to-issues` | Convert tasks to GitHub issues for project management integration |
362
362
 
363
+ #### Git Workflow Commands
364
+
365
+ | Command | Description |
366
+ |---------|-------------|
367
+ | `/codexspec.commit` | Generate Conventional Commits messages based on git status and session context |
368
+ | `/codexspec.commit-staged` | Generate commit message from staged changes only |
369
+
363
370
  ## Workflow Overview
364
371
 
365
372
  ```
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "codexspec"
3
- version = "0.3.1"
3
+ version = "0.3.2"
4
4
  description = "CodexSpec - A Spec-Driven Development (SDD) toolkit for Claude Code"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.11"
@@ -0,0 +1,31 @@
1
+ ---
2
+ description: Analyze staged git changes and generate Conventional Commits compliant commit messages
3
+ allowed-tools: Bash(git diff:*), Bash(git commit:*)
4
+ ---
5
+
6
+ ## Language Preference
7
+
8
+ **IMPORTANT**: Before proceeding, read the project's language configuration from `.codexspec/config.yml`.
9
+ - If `language.output` is set to a language other than "en", respond and generate all content in that language
10
+ - If not configured or set to "en", use English as default
11
+ - Technical terms (e.g., API, JWT, OAuth) may remain in English when appropriate
12
+ - All user-facing messages, questions, and generated documents should use the configured language
13
+
14
+ ## Instructions
15
+
16
+ 1. Execute `git diff --staged` to retrieve staged changes.
17
+
18
+ 2. Analyze the changes and generate a commit message that strictly follows **Conventional Commits** specification:
19
+ - Format: `type(scope): description`
20
+ - Types: `feat`, `fix`, `docs`, `style`, `refactor`, `perf`, `test`, `build`, `ci`, `chore`, `revert`
21
+ - If the project has a `CLAUDE.md` with custom commit conventions, follow those instead
22
+
23
+ 3. Present the generated commit message to the user and ask for confirmation.
24
+
25
+ 4. If confirmed, execute `git commit -m "..."` with the generated message.
26
+
27
+ ## Important Notes
28
+
29
+ - If no staged changes exist, inform the user and suggest using `git add` first
30
+ - For breaking changes, include `BREAKING CHANGE:` in the commit body
31
+ - Keep the description concise and in imperative mood (e.g., "add feature" not "added feature")
@@ -0,0 +1,70 @@
1
+ ---
2
+ description: Generate Conventional Commits compliant commit messages based on git status and session context
3
+ allowed-tools: Bash(git status:*), Bash(git diff:*), Bash(git branch:*), Bash(git add:*), Bash(git commit:*)
4
+ ---
5
+
6
+ ## Language Preference
7
+
8
+ **IMPORTANT**: Before proceeding, read the project's language configuration from `.codexspec/config.yml`.
9
+ - If `language.output` is set to a language other than "en", respond and generate all content in that language
10
+ - If not configured or set to "en", use English as default
11
+ - Technical terms (e.g., API, JWT, OAuth) may remain in English when appropriate
12
+ - All user-facing messages, commit messages, and interactions should use the configured language
13
+
14
+ ## Git Context Collection
15
+
16
+ Execute the following commands to gather git context:
17
+
18
+ 1. **Current Branch**: `git branch --show-current`
19
+ 2. **File Status**: `git status --short`
20
+ 3. **Staged Changes**: `git diff --staged`
21
+ 4. **Unstaged Changes**: `git diff`
22
+
23
+ ## Decision Logic
24
+
25
+ Based on the git context, follow this priority order:
26
+
27
+ ### Case A: Staged Changes Exist (Priority)
28
+
29
+ 1. Ignore unstaged changes
30
+ 2. Generate a commit message based on staged changes only
31
+ 3. Consider the current session conversation history to understand the intent and context
32
+ 4. Present the commit message to user for confirmation
33
+ 5. If confirmed, execute `git commit -m "..."`
34
+
35
+ ### Case B: No Staged Changes, But Unstaged Changes Exist
36
+
37
+ 1. **IMPORTANT**: Display a prominent warning at the beginning: "Staging area is empty. The following is a suggested commit message based on working directory changes. Please run `git add` first."
38
+ 2. Analyze the unstaged changes
39
+ 3. Generate a **suggested** commit message
40
+ 4. **REMINDER**: After displaying the commit message, repeat the reminder: "Remember: You must stage changes with `git add` before committing."
41
+ 5. Ask user if they want to stage all changes and commit
42
+
43
+ ### Case C: No Changes At All
44
+
45
+ Respond with: "Working directory is clean. No changes detected."
46
+
47
+ ## Commit Message Format
48
+
49
+ Generate commit messages following **Conventional Commits** specification:
50
+
51
+ - Format: `type(scope): description`
52
+ - Types: `feat`, `fix`, `docs`, `style`, `refactor`, `perf`, `test`, `build`, `ci`, `chore`, `revert`
53
+ - If the project has a `CLAUDE.md` with custom commit conventions, follow those instead
54
+ - For breaking changes, include `BREAKING CHANGE:` in the commit body
55
+ - Keep the description concise and in imperative mood (e.g., "add feature" not "added feature")
56
+
57
+ ## Session Context Awareness
58
+
59
+ When analyzing changes, consider:
60
+ - What the user has been working on in this session
61
+ - The purpose and goals discussed in the conversation
62
+ - Any related specifications, plans, or tasks mentioned
63
+
64
+ This context helps generate more meaningful commit messages that reflect the "why" behind the changes, not just the "what".
65
+
66
+ ## Important Notes
67
+
68
+ - Always confirm with user before executing `git commit`
69
+ - For Case B, display a prominent reminder at the **beginning** before showing the suggested commit message, AND repeat the reminder at the **end** after displaying the message. This ensures the user is aware that the commit message is generated based on unstaged changes (not staged changes), so they can take appropriate action: proceed if intentional, or re-stage specific files and run the command again if they forgot to stage.
70
+ - Do not make assumptions about change intent without context
File without changes
File without changes