cmt-cli 1.2.2__tar.gz → 1.2.3__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 (38) hide show
  1. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/PKG-INFO +1 -1
  2. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/pyproject.toml +1 -1
  3. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/git/repository.py +4 -15
  4. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/uv.lock +1 -1
  5. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/.github/workflows/test.yml +0 -0
  6. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/.gitignore +0 -0
  7. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/.python-version +0 -0
  8. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/LICENSE +0 -0
  9. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/README.md +0 -0
  10. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/art/cmt-cli.svg +0 -0
  11. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/__init__.py +0 -0
  12. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/ai/__init__.py +0 -0
  13. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/ai/cache.py +0 -0
  14. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/ai/openai.py +0 -0
  15. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/ai/prompt.py +0 -0
  16. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/ai/provider.py +0 -0
  17. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/analysis/__init__.py +0 -0
  18. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/analysis/analyzer.py +0 -0
  19. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/cli.py +0 -0
  20. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/core/__init__.py +0 -0
  21. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/core/console.py +0 -0
  22. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/core/logging.py +0 -0
  23. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/core/settings.py +0 -0
  24. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/enums/__init__.py +0 -0
  25. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/enums/config.py +0 -0
  26. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/exceptions.py +0 -0
  27. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/git/__init__.py +0 -0
  28. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/models/__init__.py +0 -0
  29. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/models/changes.py +0 -0
  30. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/models/suggestion.py +0 -0
  31. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/schemas/__init__.py +0 -0
  32. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/schemas/config.py +0 -0
  33. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/schemas/general.py +0 -0
  34. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/services/__init__.py +0 -0
  35. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/services/pypi.py +0 -0
  36. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/src/cmt/utils.py +0 -0
  37. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/tests/__init__.py +0 -0
  38. {cmt_cli-1.2.2 → cmt_cli-1.2.3}/tests/unit/test_repository.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: cmt-cli
3
- Version: 1.2.2
3
+ Version: 1.2.3
4
4
  Summary: AI-powered Git commit message generator
5
5
  Project-URL: Homepage, https://github.com/bijaydas/cmt
6
6
  Project-URL: Documentation, https://github.com/bijaydas/cmt#readme
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "cmt-cli"
3
- version = "1.2.2"
3
+ version = "1.2.3"
4
4
  description = "AI-powered Git commit message generator"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.12"
@@ -12,20 +12,12 @@ class Repository:
12
12
  def _execute(self, command: list[str]) -> subprocess.CompletedProcess:
13
13
  try:
14
14
  return subprocess.run(
15
- command,
16
- cwd=self.root,
17
- capture_output=True,
18
- check=True,
19
- text=True
15
+ command, cwd=self.root, capture_output=True, check=True, text=True
20
16
  )
21
17
  except subprocess.CalledProcessError as e:
22
- # Git writes some failure messages (e.g. "nothing to commit") to
23
- # stdout rather than stderr, so both are checked.
24
18
  output = "\n".join(filter(None, [e.stdout, e.stderr])).strip()
25
19
  output = output or "no error output was returned."
26
- raise GitError(
27
- f"Command '{' '.join(command)}' failed:\n{output}"
28
- ) from e
20
+ raise GitError(output) from e
29
21
 
30
22
  def is_git_repository(self):
31
23
  try:
@@ -51,10 +43,7 @@ class Repository:
51
43
  return result.stdout
52
44
 
53
45
  def get_staged_changes(self) -> StagedChangeSet:
54
- return StagedChangeSet(
55
- files=self._get_staged_files(),
56
- diff=self._get_staged_diff()
57
- )
46
+ return StagedChangeSet(files=self._get_staged_files(), diff=self._get_staged_diff())
58
47
 
59
48
  def commit(self, message: str) -> subprocess.CompletedProcess:
60
- return self._execute(["git", "commit", "-m", message])
49
+ return self._execute(["git", "commit", "-m", message])
@@ -175,7 +175,7 @@ wheels = [
175
175
 
176
176
  [[package]]
177
177
  name = "cmt-cli"
178
- version = "1.2.0"
178
+ version = "1.2.3"
179
179
  source = { editable = "." }
180
180
  dependencies = [
181
181
  { name = "langchain" },
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
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes