lib-cli-exit-tools 2.3.0__tar.gz → 2.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.
Files changed (57) hide show
  1. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.github/workflows/default_cicd_public.yml +120 -17
  2. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.github/workflows/default_release_public.yml +2 -2
  3. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.gitignore +2 -0
  4. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/CHANGELOG.md +11 -0
  5. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/Makefile +63 -38
  6. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/PKG-INFO +17 -13
  7. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/README.md +0 -1
  8. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/pyproject.toml +49 -44
  9. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/__init__conf__.py +1 -1
  10. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/application/runner.py +3 -3
  11. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/cli/styling.py +2 -2
  12. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/core/configuration.py +2 -2
  13. lib_cli_exit_tools-2.3.0/.claude/commands/tfbp.md +0 -84
  14. lib_cli_exit_tools-2.3.0/CLAUDE.md +0 -164
  15. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.codacy/cli-config.yaml +0 -0
  16. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.codacy/cli.sh +0 -0
  17. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.codacy/codacy.yaml +0 -0
  18. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.codacy/tools-configs/lizard.yaml +0 -0
  19. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.codacy/tools-configs/trivy.yaml +0 -0
  20. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.data_arch_violations.json +0 -0
  21. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.devcontainer/devcontainer.json +0 -0
  22. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.devcontainer/settings.json +0 -0
  23. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.env.example +0 -0
  24. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.github/actions/extract-metadata/action.yml +0 -0
  25. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.github/dependabot.yml +0 -0
  26. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.github/workflows/codeql.yml +0 -0
  27. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.qlty/qlty.toml +0 -0
  28. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/.snyk +0 -0
  29. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/CONTRIBUTING.md +0 -0
  30. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/DEVELOPMENT.md +0 -0
  31. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/INSTALL.md +0 -0
  32. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/LICENSE +0 -0
  33. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/codecov.yml +0 -0
  34. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/docs/system-design/module_reference.md +0 -0
  35. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/notebooks/Quickstart.ipynb +0 -0
  36. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/__init__.py +0 -0
  37. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/__main__.py +0 -0
  38. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/adapters/__init__.py +0 -0
  39. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/adapters/signals.py +0 -0
  40. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/application/__init__.py +0 -0
  41. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/cli/__init__.py +0 -0
  42. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/cli/commands.py +0 -0
  43. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/cli/group.py +0 -0
  44. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/core/__init__.py +0 -0
  45. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/core/exit_codes.py +0 -0
  46. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/lib_cli_exit_tools.py +0 -0
  47. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/src/lib_cli_exit_tools/py.typed +0 -0
  48. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/conftest.py +0 -0
  49. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_adapters_signals.py +0 -0
  50. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_application_runner.py +0 -0
  51. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_behaviors.py +0 -0
  52. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_cli.py +0 -0
  53. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_core_configuration.py +0 -0
  54. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_core_exit_codes.py +0 -0
  55. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_metadata.py +0 -0
  56. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_module_entry.py +0 -0
  57. {lib_cli_exit_tools-2.3.0 → lib_cli_exit_tools-2.3.1}/tests/test_signals_integration.py +0 -0
@@ -10,15 +10,56 @@ on:
10
10
  - cron: '17 3 * * *'
11
11
 
12
12
  jobs:
13
+ setup:
14
+ name: Extract Python versions and OS matrix from pyproject.toml
15
+ runs-on: ubuntu-latest
16
+ outputs:
17
+ python-versions: ${{ steps.metadata.outputs.python-versions }}
18
+ python-latest: ${{ steps.metadata.outputs.python-latest }}
19
+ os-matrix: ${{ steps.metadata.outputs.os-matrix }}
20
+ steps:
21
+ - uses: actions/checkout@v6
22
+ - uses: actions/setup-python@v6
23
+ with:
24
+ python-version: "3.x"
25
+ - name: Parse pyproject.toml for Python versions and OS matrix
26
+ id: metadata
27
+ shell: python
28
+ run: |
29
+ import json, os, tomllib
30
+
31
+ with open("pyproject.toml", "rb") as f:
32
+ data = tomllib.load(f)
33
+
34
+ # Python versions from classifiers
35
+ classifiers = data.get("project", {}).get("classifiers", [])
36
+ prefix = "Programming Language :: Python :: "
37
+ versions = [
38
+ c[len(prefix):]
39
+ for c in classifiers
40
+ if c.startswith(prefix) and "." in c[len(prefix):]
41
+ ]
42
+ if not versions:
43
+ raise SystemExit("No Python X.Y versions found in classifiers")
44
+
45
+ # OS matrix from [tool.ci]
46
+ ci_config = data.get("tool", {}).get("ci", {})
47
+ os_list = ci_config.get("os", ["ubuntu-latest"])
48
+
49
+ with open(os.environ["GITHUB_OUTPUT"], "a") as fh:
50
+ fh.write(f"python-versions={json.dumps(versions)}\n")
51
+ fh.write(f"python-latest={versions[-1]}\n")
52
+ fh.write(f"os-matrix={json.dumps(os_list)}\n")
53
+
13
54
  test:
14
55
  name: Tests (Python ${{ matrix.python }}, ${{ matrix.os }})
56
+ needs: setup
15
57
  runs-on: ${{ matrix.os }}
16
58
  strategy:
17
59
  fail-fast: false
18
60
  matrix:
19
- os: [ubuntu-latest, macos-latest, windows-latest]
20
- # Test against all supported Python versions (3.10+)
21
- python: ["3.10", "3.11", "3.12", "3.13", "3.14"]
61
+ os: ${{ fromJSON(needs.setup.outputs.os-matrix) }}
62
+ python: ${{ fromJSON(needs.setup.outputs.python-versions) }}
22
63
  env:
23
64
  PYO3_USE_ABI3_FORWARD_COMPATIBILITY: "1"
24
65
  PYTHONIOENCODING: "utf-8"
@@ -45,25 +86,88 @@ jobs:
45
86
  id: metadata
46
87
  uses: ./.github/actions/extract-metadata
47
88
 
48
- - name: Install journald prerequisites
89
+ - name: Install CI system dependencies (Ubuntu)
49
90
  if: runner.os == 'Linux'
50
- shell: bash
91
+ shell: python
51
92
  run: |
52
- sudo apt-get update
53
- sudo apt-get install -y python3-systemd
93
+ import subprocess
94
+ try:
95
+ import tomllib
96
+ except ModuleNotFoundError:
97
+ import pip._vendor.tomli as tomllib
98
+ with open("pyproject.toml", "rb") as f:
99
+ data = tomllib.load(f)
100
+ deps = data.get("tool", {}).get("ci", {}).get("system-dependencies-ubuntu", [])
101
+ if deps:
102
+ print(f"Installing system packages: {' '.join(deps)}")
103
+ subprocess.check_call(["sudo", "apt-get", "update"])
104
+ subprocess.check_call(["sudo", "apt-get", "install", "-y", *deps])
105
+ else:
106
+ print("No CI system dependencies configured for Ubuntu.")
107
+
108
+ - name: Install CI system dependencies (macOS)
109
+ if: runner.os == 'macOS'
110
+ shell: python
111
+ run: |
112
+ import subprocess
113
+ try:
114
+ import tomllib
115
+ except ModuleNotFoundError:
116
+ import pip._vendor.tomli as tomllib
117
+ with open("pyproject.toml", "rb") as f:
118
+ data = tomllib.load(f)
119
+ deps = data.get("tool", {}).get("ci", {}).get("system-dependencies-macos", [])
120
+ if deps:
121
+ print(f"Installing system packages: {' '.join(deps)}")
122
+ subprocess.check_call(["brew", "install", *deps])
123
+ else:
124
+ print("No CI system dependencies configured for macOS.")
54
125
 
55
126
  - name: Install dev deps
56
127
  shell: bash
57
128
  run: |
58
129
  uv pip install -e .[dev] --system
59
130
 
60
- - name: Install Windows Event Log prerequisites
131
+ - name: Install CI system dependencies (Windows/choco)
61
132
  if: runner.os == 'Windows'
62
- shell: bash
133
+ shell: python
63
134
  run: |
64
- uv pip install pywin32 --system
65
-
135
+ import subprocess
136
+ try:
137
+ import tomllib
138
+ except ModuleNotFoundError:
139
+ import pip._vendor.tomli as tomllib
140
+ with open("pyproject.toml", "rb") as f:
141
+ data = tomllib.load(f)
142
+ deps = data.get("tool", {}).get("ci", {}).get("system-dependencies-windows-choco", [])
143
+ if deps:
144
+ print(f"Installing choco packages: {' '.join(deps)}")
145
+ subprocess.check_call(["choco", "install", "-y", *deps])
146
+ else:
147
+ print("No CI choco dependencies configured for Windows.")
148
+
149
+ - name: Install CI pip dependencies (Windows)
150
+ if: runner.os == 'Windows'
151
+ shell: python
152
+ run: |
153
+ import subprocess
154
+ try:
155
+ import tomllib
156
+ except ModuleNotFoundError:
157
+ import pip._vendor.tomli as tomllib
158
+ with open("pyproject.toml", "rb") as f:
159
+ data = tomllib.load(f)
160
+ deps = data.get("tool", {}).get("ci", {}).get("system-dependencies-windows-pip", [])
161
+ if deps:
162
+ print(f"Installing pip packages: {' '.join(deps)}")
163
+ subprocess.check_call(["uv", "pip", "install", *deps, "--system"])
164
+ else:
165
+ print("No CI pip dependencies configured for Windows.")
166
+
167
+ # Self-hosted runners persist ruff cache via RUFF_CACHE_DIR volume mount,
168
+ # so actions/cache is only needed on GitHub-hosted runners.
66
169
  - name: Restore ruff cache
170
+ if: runner.environment == 'github-hosted'
67
171
  id: ruff-cache
68
172
  uses: actions/cache/restore@v5
69
173
  with:
@@ -109,8 +213,8 @@ jobs:
109
213
  always()
110
214
  && steps.pytest.outcome == 'success'
111
215
  && matrix.os == 'ubuntu-latest'
112
- && matrix.python == '3.13'
113
- uses: codecov/codecov-action@v5
216
+ && matrix.python == needs.setup.outputs.python-latest
217
+ uses: codecov/codecov-action@v6
114
218
  with:
115
219
  files: ${{ env.COV_REPORT_FILE }}
116
220
  fail_ci_if_error: false
@@ -125,7 +229,7 @@ jobs:
125
229
  id: bandit
126
230
  continue-on-error: true
127
231
  shell: bash
128
- run: bandit -q -r ${{ env.SRC_PATH }}/${{ env.PACKAGE_MODULE }} ${{ env.BANDIT_SKIP_FLAG }}
232
+ run: bandit -q -c pyproject.toml -r ${{ env.SRC_PATH }}/${{ env.PACKAGE_MODULE }} ${{ env.BANDIT_SKIP_FLAG }}
129
233
 
130
234
  - name: Run pip-audit (vulnerability scan)
131
235
  id: pipaudit
@@ -166,8 +270,7 @@ jobs:
166
270
  exit 1
167
271
  fi
168
272
  if [[ "${{ steps.pipaudit.outcome }}" != "success" ]]; then
169
- echo "::error::pip-audit vulnerability scan failed"
170
- exit 1
273
+ echo "::warning::pip-audit vulnerability scan failed"
171
274
  fi
172
275
  echo "All checks passed!"
173
276
 
@@ -189,7 +292,7 @@ jobs:
189
292
  run: uv cache prune --ci
190
293
 
191
294
  - name: Save ruff cache
192
- if: always() && steps.ruff-cache.outputs.cache-hit != 'true'
295
+ if: always() && runner.environment == 'github-hosted' && steps.ruff-cache.outputs.cache-hit != 'true'
193
296
  uses: actions/cache/save@v5
194
297
  with:
195
298
  path: .ruff_cache
@@ -31,7 +31,7 @@ jobs:
31
31
  run: uv build
32
32
 
33
33
  - name: Upload artifacts
34
- uses: actions/upload-artifact@v6
34
+ uses: actions/upload-artifact@v7
35
35
  with:
36
36
  name: dist
37
37
  path: dist/*
@@ -56,7 +56,7 @@ jobs:
56
56
  fi
57
57
 
58
58
  - name: Download artifacts
59
- uses: actions/download-artifact@v7
59
+ uses: actions/download-artifact@v8
60
60
  with:
61
61
  name: dist
62
62
  path: dist/
@@ -180,3 +180,5 @@ pdm.lock
180
180
  uv.lock
181
181
  /.github_bak/
182
182
  prompts.md
183
+ CLAUDE.md
184
+ .claude/
@@ -4,6 +4,17 @@ All notable changes to this project are documented here. The format follows [Kee
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [2.3.1] - 2026-04-24
8
+
9
+ ### Fixed
10
+ - Replaced `Iterator[...]` with `Generator[...]` in return annotations of `@contextmanager`-decorated functions (`config_overrides`, `cli_session`, `_apply_overrides_without_restore`, `_temporary_rich_click_configuration`) to satisfy pyright 1.1.409's new deprecation check that was breaking CI.
11
+
12
+ ### Security
13
+ - Refreshed pip-audit `ignore-vulns`: dropped entries whose packages are now at fixed versions; added dev/env-only exclusions for authlib (GHSA-jj8c-mmj3-mmgv), cryptography (CVE-2026-39892), lxml (CVE-2026-41066), Pillow (CVE-2026-40192), python-multipart (CVE-2026-40347), and uv (GHSA-pjjw-68hj-v9mw). None of these packages are runtime dependencies of `lib_cli_exit_tools`.
14
+
15
+ ### Changed
16
+ - Bumped dev dependency minimums in `pyproject.toml` and refreshed the BMK Makefile wrapper to 2.9.1 (persistent `uv tool install`).
17
+
7
18
  ## [2.3.0] - 2026-02-13
8
19
 
9
20
  ### Added
@@ -1,7 +1,7 @@
1
- # BMK MAKEFILE 2.3.2
1
+ # BMK MAKEFILE 2.9.1
2
2
  # do not alter this file - it might be overwritten on new versions of BMK
3
3
  # if You want to alter it, remove the first line # BMK MAKEFILE 1.0 - then it is a custom makefile and will not be overwritten
4
- # bmk Makefile — thin wrapper calling bmk via uvx
4
+ # bmk Makefile — thin wrapper using `uv tool install` for persistent bmk
5
5
  #
6
6
  # Usage:
7
7
  # make test # run test suite
@@ -11,8 +11,10 @@
11
11
  # make custom deploy # run custom command
12
12
  # make custom deploy --dry-run
13
13
  #
14
- # All targets invoke `uvx bmk@latest` so the latest published
15
- # version is always used, regardless of local install state.
14
+ # On every invocation, bmk is (re-)installed as a persistent uv tool
15
+ # together with the current project's dependencies (read from ./pyproject.toml).
16
+ # This ensures pyright, pytest, pip-audit etc. can resolve the full
17
+ # dependency tree without PYTHONPATH hacks or a local .venv.
16
18
  #
17
19
  # Arguments after the target name are forwarded automatically.
18
20
  # You can also use ARGS="..." explicitly if preferred.
@@ -20,9 +22,19 @@
20
22
  SHELL := /bin/bash
21
23
  .DEFAULT_GOAL := help
22
24
 
23
- BMK := uvx bmk@latest
25
+ # Use absolute path to the uv tool binary so active virtualenvs cannot shadow it.
26
+ BMK := $(HOME)/.local/bin/bmk
24
27
  ARGS ?=
25
28
 
29
+ # ──────────────────────────────────────────────────────────────
30
+ # Ensure bmk + project deps are installed as a persistent uv tool
31
+ # ──────────────────────────────────────────────────────────────
32
+ # --reinstall re-resolves deps on every call (fast when cached).
33
+ # Fallback handles first-time install where --reinstall would fail.
34
+ .PHONY: _ensure_bmk
35
+ _ensure_bmk:
36
+ @uv tool install --reinstall bmk --with . 2>/dev/null || uv tool install bmk --with .
37
+
26
38
  # ──────────────────────────────────────────────────────────────
27
39
  # Argument forwarding via MAKECMDGOALS
28
40
  # ──────────────────────────────────────────────────────────────
@@ -30,7 +42,8 @@ ARGS ?=
30
42
  # instead of: make push ARGS="fix login bug"
31
43
 
32
44
  # All targets that accept trailing arguments
33
- _BMK_TARGETS := test t testintegration testi ti codecov coverage cov \
45
+ _BMK_TARGETS := test t test-human th testintegration testi ti testintegration-human tih \
46
+ codecov coverage cov \
34
47
  build bld clean cln cl run \
35
48
  bump-major bump-minor bump-patch bump \
36
49
  commit c push psh p release rel r \
@@ -51,21 +64,33 @@ endif
51
64
  # ──────────────────────────────────────────────────────────────
52
65
 
53
66
  .PHONY: test t
54
- test: ## Run test suite [alias: t]
67
+ test: _ensure_bmk ## Run test suite [alias: t]
55
68
  $(BMK) test $(ARGS)
56
- t:
69
+ t: _ensure_bmk
57
70
  $(BMK) test $(ARGS)
58
71
 
72
+ .PHONY: test-human th
73
+ test-human: _ensure_bmk ## Run test suite with human-readable output [alias: th]
74
+ $(BMK) test --human $(ARGS)
75
+ th: _ensure_bmk
76
+ $(BMK) test --human $(ARGS)
77
+
59
78
  .PHONY: testintegration testi ti
60
- testintegration: ## Run integration tests only [aliases: testi, ti]
79
+ testintegration: _ensure_bmk ## Run integration tests only [aliases: testi, ti]
61
80
  $(BMK) testintegration $(ARGS)
62
- testi ti:
81
+ testi ti: _ensure_bmk
63
82
  $(BMK) testintegration $(ARGS)
64
83
 
84
+ .PHONY: testintegration-human tih
85
+ testintegration-human: _ensure_bmk ## Run integration tests with human-readable output [alias: tih]
86
+ $(BMK) testintegration --human $(ARGS)
87
+ tih: _ensure_bmk
88
+ $(BMK) testintegration --human $(ARGS)
89
+
65
90
  .PHONY: codecov coverage cov
66
- codecov: ## Upload coverage report to Codecov [aliases: coverage, cov]
91
+ codecov: _ensure_bmk ## Upload coverage report to Codecov [aliases: coverage, cov]
67
92
  $(BMK) codecov $(ARGS)
68
- coverage cov:
93
+ coverage cov: _ensure_bmk
69
94
  $(BMK) codecov $(ARGS)
70
95
 
71
96
  # ──────────────────────────────────────────────────────────────
@@ -73,15 +98,15 @@ coverage cov:
73
98
  # ──────────────────────────────────────────────────────────────
74
99
 
75
100
  .PHONY: build bld
76
- build: ## Build wheel and sdist artifacts [alias: bld]
101
+ build: _ensure_bmk ## Build wheel and sdist artifacts [alias: bld]
77
102
  $(BMK) build $(ARGS)
78
- bld:
103
+ bld: _ensure_bmk
79
104
  $(BMK) build $(ARGS)
80
105
 
81
106
  .PHONY: clean cln cl
82
- clean: ## Remove build artifacts and caches [aliases: cln, cl]
107
+ clean: _ensure_bmk ## Remove build artifacts and caches [aliases: cln, cl]
83
108
  $(BMK) clean $(ARGS)
84
- cln cl:
109
+ cln cl: _ensure_bmk
85
110
  $(BMK) clean $(ARGS)
86
111
 
87
112
  # ──────────────────────────────────────────────────────────────
@@ -89,7 +114,7 @@ cln cl:
89
114
  # ──────────────────────────────────────────────────────────────
90
115
 
91
116
  .PHONY: run
92
- run: ## Run the project CLI via uvx
117
+ run: _ensure_bmk ## Run the project CLI
93
118
  $(BMK) run $(ARGS)
94
119
 
95
120
  # ──────────────────────────────────────────────────────────────
@@ -97,15 +122,15 @@ run: ## Run the project CLI via uvx
97
122
  # ──────────────────────────────────────────────────────────────
98
123
 
99
124
  .PHONY: bump-major
100
- bump-major: ## Bump major version (X+1).0.0
125
+ bump-major: _ensure_bmk ## Bump major version (X+1).0.0
101
126
  $(BMK) bump major $(ARGS)
102
127
 
103
128
  .PHONY: bump-minor
104
- bump-minor: ## Bump minor version X.(Y+1).0
129
+ bump-minor: _ensure_bmk ## Bump minor version X.(Y+1).0
105
130
  $(BMK) bump minor $(ARGS)
106
131
 
107
132
  .PHONY: bump-patch
108
- bump-patch: ## Bump patch version X.Y.(Z+1)
133
+ bump-patch: _ensure_bmk ## Bump patch version X.Y.(Z+1)
109
134
  $(BMK) bump patch $(ARGS)
110
135
 
111
136
  .PHONY: bump
@@ -116,21 +141,21 @@ bump: bump-patch ## Bump patch version (default for bump)
116
141
  # ──────────────────────────────────────────────────────────────
117
142
 
118
143
  .PHONY: commit c
119
- commit: ## Create a git commit with timestamped message [alias: c]
144
+ commit: _ensure_bmk ## Create a git commit with timestamped message [alias: c]
120
145
  $(BMK) commit $(ARGS)
121
- c:
146
+ c: _ensure_bmk
122
147
  $(BMK) commit $(ARGS)
123
148
 
124
149
  .PHONY: push psh p
125
- push: ## Run tests, commit, and push to remote [aliases: psh, p]
150
+ push: _ensure_bmk ## Run tests, commit, and push to remote [aliases: psh, p]
126
151
  $(BMK) push $(ARGS)
127
- psh p:
152
+ psh p: _ensure_bmk
128
153
  $(BMK) push $(ARGS)
129
154
 
130
155
  .PHONY: release rel r
131
- release: ## Create a versioned release (tag + GitHub release) [aliases: rel, r]
156
+ release: _ensure_bmk ## Create a versioned release (tag + GitHub release) [aliases: rel, r]
132
157
  $(BMK) release $(ARGS)
133
- rel r:
158
+ rel r: _ensure_bmk
134
159
  $(BMK) release $(ARGS)
135
160
 
136
161
  # ──────────────────────────────────────────────────────────────
@@ -138,13 +163,13 @@ rel r:
138
163
  # ──────────────────────────────────────────────────────────────
139
164
 
140
165
  .PHONY: dependencies deps d
141
- dependencies: ## Check and list project dependencies [aliases: deps, d]
166
+ dependencies: _ensure_bmk ## Check and list project dependencies [aliases: deps, d]
142
167
  $(BMK) dependencies $(ARGS)
143
- deps d:
168
+ deps d: _ensure_bmk
144
169
  $(BMK) dependencies $(ARGS)
145
170
 
146
171
  .PHONY: dependencies-update
147
- dependencies-update: ## Update dependencies to latest versions
172
+ dependencies-update: _ensure_bmk ## Update dependencies to latest versions
148
173
  $(BMK) dependencies update $(ARGS)
149
174
 
150
175
  # ──────────────────────────────────────────────────────────────
@@ -152,15 +177,15 @@ dependencies-update: ## Update dependencies to latest versions
152
177
  # ──────────────────────────────────────────────────────────────
153
178
 
154
179
  .PHONY: config
155
- config: ## Show current merged configuration
180
+ config: _ensure_bmk ## Show current merged configuration
156
181
  $(BMK) config $(ARGS)
157
182
 
158
183
  .PHONY: config-deploy
159
- config-deploy: ## Deploy configuration to system/user directories
184
+ config-deploy: _ensure_bmk ## Deploy configuration to system/user directories
160
185
  $(BMK) config-deploy $(ARGS)
161
186
 
162
187
  .PHONY: config-generate-examples
163
- config-generate-examples: ## Generate example configuration files
188
+ config-generate-examples: _ensure_bmk ## Generate example configuration files
164
189
  $(BMK) config-generate-examples $(ARGS)
165
190
 
166
191
  # ──────────────────────────────────────────────────────────────
@@ -168,11 +193,11 @@ config-generate-examples: ## Generate example configuration files
168
193
  # ──────────────────────────────────────────────────────────────
169
194
 
170
195
  .PHONY: send-email
171
- send-email: ## Send an email via configured SMTP
196
+ send-email: _ensure_bmk ## Send an email via configured SMTP
172
197
  $(BMK) send-email $(ARGS)
173
198
 
174
199
  .PHONY: send-notification
175
- send-notification: ## Send a plain-text notification email
200
+ send-notification: _ensure_bmk ## Send a plain-text notification email
176
201
  $(BMK) send-notification $(ARGS)
177
202
 
178
203
  # ──────────────────────────────────────────────────────────────
@@ -180,7 +205,7 @@ send-notification: ## Send a plain-text notification email
180
205
  # ──────────────────────────────────────────────────────────────
181
206
 
182
207
  .PHONY: custom
183
- custom: ## Run a custom command (make custom <name> [args...])
208
+ custom: _ensure_bmk ## Run a custom command (make custom <name> [args...])
184
209
  $(BMK) custom $(ARGS)
185
210
 
186
211
  # ──────────────────────────────────────────────────────────────
@@ -188,15 +213,15 @@ custom: ## Run a custom command (make custom <name> [args...])
188
213
  # ──────────────────────────────────────────────────────────────
189
214
 
190
215
  .PHONY: info
191
- info: ## Print resolved package metadata
216
+ info: _ensure_bmk ## Print resolved package metadata
192
217
  $(BMK) info $(ARGS)
193
218
 
194
219
  .PHONY: logdemo
195
- logdemo: ## Run logging demonstration
220
+ logdemo: _ensure_bmk ## Run logging demonstration
196
221
  $(BMK) logdemo $(ARGS)
197
222
 
198
223
  .PHONY: version-current
199
- version-current: ## Print current version
224
+ version-current: _ensure_bmk ## Print current version
200
225
  $(BMK) --version
201
226
 
202
227
  # ──────────────────────────────────────────────────────────────
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: lib_cli_exit_tools
3
- Version: 2.3.0
3
+ Version: 2.3.1
4
4
  Summary: CLI exit handling helpers: clean signals, exit codes, and error printing
5
5
  Project-URL: Homepage, https://github.com/bitranox/lib_cli_exit_tools
6
6
  Project-URL: Repository, https://github.com/bitranox/lib_cli_exit_tools.git
@@ -14,24 +14,29 @@ Classifier: License :: OSI Approved :: MIT License
14
14
  Classifier: Operating System :: OS Independent
15
15
  Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3 :: Only
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Programming Language :: Python :: 3.14
17
22
  Classifier: Typing :: Typed
18
23
  Requires-Python: >=3.10
19
24
  Requires-Dist: rich-click>=1.9.7
20
25
  Provides-Extra: dev
21
- Requires-Dist: bandit>=1.9.3; extra == 'dev'
22
- Requires-Dist: build>=1.4.0; extra == 'dev'
23
- Requires-Dist: codecov-cli>=11.2.6; extra == 'dev'
24
- Requires-Dist: coverage[toml]>=7.13.4; extra == 'dev'
25
- Requires-Dist: hypothesis>=6.151.6; extra == 'dev'
26
- Requires-Dist: import-linter>=2.10; extra == 'dev'
26
+ Requires-Dist: bandit>=1.9.4; extra == 'dev'
27
+ Requires-Dist: build>=1.4.4; extra == 'dev'
28
+ Requires-Dist: codecov-cli>=11.2.8; extra == 'dev'
29
+ Requires-Dist: coverage[toml]>=7.13.5; extra == 'dev'
30
+ Requires-Dist: hypothesis>=6.152.2; extra == 'dev'
31
+ Requires-Dist: import-linter>=2.11; extra == 'dev'
27
32
  Requires-Dist: pip-audit>=2.10.0; extra == 'dev'
28
- Requires-Dist: pyright[nodejs]>=1.1.408; extra == 'dev'
33
+ Requires-Dist: pyright[nodejs]>=1.1.409; extra == 'dev'
29
34
  Requires-Dist: pytest-asyncio>=1.3.0; extra == 'dev'
30
- Requires-Dist: pytest-cov>=7.0.0; extra == 'dev'
31
- Requires-Dist: pytest>=9.0.2; extra == 'dev'
35
+ Requires-Dist: pytest-cov>=7.1.0; extra == 'dev'
36
+ Requires-Dist: pytest>=9.0.3; extra == 'dev'
32
37
  Requires-Dist: rtoml>=0.13.0; extra == 'dev'
33
- Requires-Dist: ruff>=0.15.1; extra == 'dev'
34
- Requires-Dist: textual>=7.5.0; extra == 'dev'
38
+ Requires-Dist: ruff>=0.15.11; extra == 'dev'
39
+ Requires-Dist: textual>=8.2.4; extra == 'dev'
35
40
  Requires-Dist: twine>=6.2.0; extra == 'dev'
36
41
  Description-Content-Type: text/markdown
37
42
 
@@ -47,7 +52,6 @@ Description-Content-Type: text/markdown
47
52
  [![Code Style: Ruff](https://img.shields.io/badge/Code%20Style-Ruff-46A3FF?logo=ruff&labelColor=000)](https://docs.astral.sh/ruff/)
48
53
  [![codecov](https://codecov.io/gh/bitranox/lib_cli_exit_tools/graph/badge.svg?token=z1D8JSjWEH)](https://codecov.io/gh/bitranox/lib_cli_exit_tools)
49
54
  [![Maintainability](https://qlty.sh/gh/bitranox/projects/lib_cli_exit_tools/maintainability.svg)](https://qlty.sh/gh/bitranox/projects/lib_cli_exit_tools)
50
- [![Known Vulnerabilities](https://snyk.io/test/github/bitranox/lib_cli_exit_tools/badge.svg)](https://snyk.io/test/github/bitranox/lib_cli_exit_tools)
51
55
  [![security: bandit](https://img.shields.io/badge/security-bandit-yellow.svg)](https://github.com/PyCQA/bandit)
52
56
 
53
57
  Small helpers for robust CLI exit handling:
@@ -10,7 +10,6 @@
10
10
  [![Code Style: Ruff](https://img.shields.io/badge/Code%20Style-Ruff-46A3FF?logo=ruff&labelColor=000)](https://docs.astral.sh/ruff/)
11
11
  [![codecov](https://codecov.io/gh/bitranox/lib_cli_exit_tools/graph/badge.svg?token=z1D8JSjWEH)](https://codecov.io/gh/bitranox/lib_cli_exit_tools)
12
12
  [![Maintainability](https://qlty.sh/gh/bitranox/projects/lib_cli_exit_tools/maintainability.svg)](https://qlty.sh/gh/bitranox/projects/lib_cli_exit_tools)
13
- [![Known Vulnerabilities](https://snyk.io/test/github/bitranox/lib_cli_exit_tools/badge.svg)](https://snyk.io/test/github/bitranox/lib_cli_exit_tools)
14
13
  [![security: bandit](https://img.shields.io/badge/security-bandit-yellow.svg)](https://github.com/PyCQA/bandit)
15
14
 
16
15
  Small helpers for robust CLI exit handling:
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "lib_cli_exit_tools"
3
- version = "2.3.0"
3
+ version = "2.3.1"
4
4
  description = "CLI exit handling helpers: clean signals, exit codes, and error printing"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.10"
@@ -9,14 +9,28 @@ license = { text = "MIT" }
9
9
  authors = [{ name = "bitranox", email = "bitranox@gmail.com" }]
10
10
  keywords = ["cli", "exit", "signals", "errors", "click"]
11
11
  classifiers = [
12
- "Programming Language :: Python :: 3",
13
- "Programming Language :: Python :: 3 :: Only",
14
12
  "License :: OSI Approved :: MIT License",
15
13
  "Environment :: Console",
16
14
  "Operating System :: OS Independent",
17
15
  "Typing :: Typed",
16
+ "Programming Language :: Python :: 3",
17
+ "Programming Language :: Python :: 3 :: Only",
18
+ "Programming Language :: Python :: 3.10",
19
+ "Programming Language :: Python :: 3.11",
20
+ "Programming Language :: Python :: 3.12",
21
+ "Programming Language :: Python :: 3.13",
22
+ "Programming Language :: Python :: 3.14",
18
23
  ]
19
24
 
25
+ # System packages required for CI runners (read by GitHub Actions workflow template)
26
+ # Format: "apt_package_name" for Ubuntu, future: {"apt": "...", "brew": "...", "choco": "..."}
27
+ [tool.ci]
28
+ system-dependencies-ubuntu = []
29
+ system-dependencies-macos = []
30
+ system-dependencies-windows-pip = []
31
+ system-dependencies-windows-choco = []
32
+ os = ["ubuntu-latest", "windows-latest", "macos-latest"]
33
+
20
34
  [project.urls]
21
35
  Homepage = "https://github.com/bitranox/lib_cli_exit_tools"
22
36
  Repository = "https://github.com/bitranox/lib_cli_exit_tools.git"
@@ -24,19 +38,19 @@ Issues = "https://github.com/bitranox/lib_cli_exit_tools/issues"
24
38
 
25
39
  [project.optional-dependencies]
26
40
  dev = [
27
- "build>=1.4.0",
28
- "codecov-cli>=11.2.6",
29
- "coverage[toml]>=7.13.4",
30
- "hypothesis>=6.151.6",
31
- "import-linter>=2.10",
32
- "bandit>=1.9.3",
41
+ "build>=1.4.4",
42
+ "codecov-cli>=11.2.8",
43
+ "coverage[toml]>=7.13.5",
44
+ "hypothesis>=6.152.2",
45
+ "import-linter>=2.11",
46
+ "bandit>=1.9.4",
33
47
  "pip-audit>=2.10.0",
34
- "pyright[nodejs]>=1.1.408",
35
- "pytest>=9.0.2",
48
+ "pyright[nodejs]>=1.1.409",
49
+ "pytest>=9.0.3",
36
50
  "pytest-asyncio>=1.3.0",
37
- "pytest-cov>=7.0.0",
38
- "ruff>=0.15.1",
39
- "textual>=7.5.0",
51
+ "pytest-cov>=7.1.0",
52
+ "ruff>=0.15.11",
53
+ "textual>=8.2.4",
40
54
  "rtoml>=0.13.0",
41
55
  "twine>=6.2.0"
42
56
  ]
@@ -48,7 +62,7 @@ cli-exit-tools = "lib_cli_exit_tools.cli:main"
48
62
  lib-cli-exit-tools = "lib_cli_exit_tools.cli:main"
49
63
 
50
64
  [build-system]
51
- requires = ["hatchling>=1.28.0"]
65
+ requires = ["hatchling>=1.29.0"]
52
66
  build-backend = "hatchling.build"
53
67
 
54
68
  [tool.hatch.build.targets.wheel]
@@ -95,8 +109,9 @@ fail_under = 85
95
109
  show_missing = true
96
110
 
97
111
  [tool.clean]
98
- # Patterns to remove when running `make clean` or `python -m scripts clean`
112
+ # Patterns to remove when running `make clean`
99
113
  patterns = [
114
+ "**/__pycache__",
100
115
  ".hypothesis",
101
116
  ".import_linter_cache",
102
117
  ".pytest_cache",
@@ -155,33 +170,23 @@ forbidden_modules = [
155
170
 
156
171
  [tool.pip-audit]
157
172
  # Known vulnerabilities to ignore (unfixable or accepted risk)
158
- # GHSA-4xh5-x5gv-qwph: py library ReDoS (no fix available, low risk)
159
- # PYSEC-2022-42969: same as above (alias)
160
- # PYSEC-2022-43012, CVE-2024-6345, PYSEC-2025-49: setuptools vulnerabilities
161
- # These are build-time dependencies only, not runtime. The virtual environment
162
- # setuptools version is managed by the CI environment/pip itself.
163
- # CVE-2025-68146: filelock <3.20.1 vulnerability, transitive dev dependency
164
- # Will be resolved when upstream packages update their dependencies.
165
- # CVE-2026-23949: jaraco-context <6.1.0, transitive dev dependency
166
- # CVE-2025-69277: pynacl <1.6.2, transitive dev dependency
167
- # CVE-2026-21441: urllib3 <2.6.3, transitive dev dependency
168
- # CVE-2026-22702: virtualenv <20.36.1, transitive dev dependency
169
- # CVE-2026-24049: wheel <0.46.2, build-time dependency
170
- # CVE-2026-24486: python-multipart <0.0.22, transitive dev dependency
173
+ # Runtime deps of lib_cli_exit_tools are limited to rich-click; entries below
174
+ # are dev/env-only transitive vulnerabilities that do not affect library users.
171
175
  ignore-vulns = [
172
- "GHSA-4xh5-x5gv-qwph",
173
- "PYSEC-2022-42969",
174
- "PYSEC-2022-43012",
175
- "CVE-2024-6345",
176
- "PYSEC-2025-49",
177
- "CVE-2025-68146",
178
- "CVE-2026-23949",
179
- "CVE-2025-69277",
180
- "CVE-2026-21441",
181
- "CVE-2026-22702",
182
- "CVE-2026-24049",
183
- "CVE-2026-24486",
184
- "CVE-2026-1703",
185
- "CVE-2026-25990",
186
- "CVE-2026-26007"
176
+ "GHSA-4xh5-x5gv-qwph", # py library ReDoS, no fix available, dev-only
177
+ "PYSEC-2022-42969", # alias of GHSA-4xh5-x5gv-qwph
178
+ "CVE-2026-1703", # transitive dev dependency, upstream tracking
179
+ "CVE-2026-25990", # transitive dev dependency, upstream tracking
180
+ "CVE-2026-26007", # transitive dev dependency, upstream tracking
181
+ "CVE-2026-25645", # transitive dev dependency, upstream tracking
182
+ "GHSA-jj8c-mmj3-mmgv", # authlib <1.6.11 CSRF in cache feature, dev-only (bmk tooling chain)
183
+ "CVE-2026-39892", # cryptography <46.0.7 Hash.update buffer overflow, dev-only
184
+ "GHSA-p423-j2cm-9vmq", # alias of CVE-2026-39892
185
+ "CVE-2026-41066", # lxml <6.1.0 XXE via default resolve_entities, dev-only
186
+ "GHSA-vfmq-68hx-4jfw", # alias of CVE-2026-41066
187
+ "CVE-2026-40192", # Pillow <12.2.0 FITS decompression bomb, dev-only
188
+ "GHSA-whj4-6x5x-4v2j", # alias of CVE-2026-40192
189
+ "CVE-2026-40347", # python-multipart <0.0.26 DoS via crafted preamble/epilogue, dev-only
190
+ "GHSA-mj87-hwqh-73pj", # alias of CVE-2026-40347
191
+ "GHSA-pjjw-68hj-v9mw", # uv <0.11.6 wheel RECORD path traversal on uninstall, dev tooling
187
192
  ]
@@ -24,7 +24,7 @@ name = "lib_cli_exit_tools"
24
24
  #: Human-readable summary shown in CLI help output.
25
25
  title = "CLI exit handling helpers: clean signals, exit codes, and error printing"
26
26
  #: Current release version pulled from ``pyproject.toml`` by automation.
27
- version = "2.3.0"
27
+ version = "2.3.1"
28
28
  #: Repository homepage presented to users.
29
29
  homepage = "https://github.com/bitranox/lib_cli_exit_tools"
30
30
  #: Author attribution surfaced in CLI output.
@@ -20,7 +20,7 @@ from __future__ import annotations
20
20
 
21
21
  import sys
22
22
  from contextlib import contextmanager, nullcontext, suppress
23
- from typing import Callable, ContextManager, Iterable, Iterator, Literal, Protocol, Sequence, TextIO, TypedDict, cast
23
+ from typing import Callable, ContextManager, Generator, Iterable, Literal, Protocol, Sequence, TextIO, TypedDict, cast
24
24
 
25
25
  import rich_click as click
26
26
  from rich_click import rich_click as rich_config
@@ -461,7 +461,7 @@ def cli_session(
461
461
  verbose_limit: int = 10_000,
462
462
  overrides: SessionOverrides | None = None,
463
463
  restore: bool = True,
464
- ) -> Iterator[
464
+ ) -> Generator[
465
465
  Callable[
466
466
  [
467
467
  ClickCommand,
@@ -571,7 +571,7 @@ def _session_config_manager(applied: SessionOverrides, restore: bool) -> Context
571
571
 
572
572
 
573
573
  @contextmanager
574
- def _apply_overrides_without_restore(applied: SessionOverrides) -> Iterator[None]:
574
+ def _apply_overrides_without_restore(applied: SessionOverrides) -> Generator[None]:
575
575
  """Apply overrides without restoring prior state on exit.
576
576
 
577
577
  Parameters:
@@ -16,7 +16,7 @@ System Integration:
16
16
  from __future__ import annotations
17
17
 
18
18
  from contextlib import contextmanager
19
- from typing import Any, Iterator, TypedDict
19
+ from typing import Any, Generator, TypedDict
20
20
 
21
21
  import rich_click as click
22
22
  from rich_click import rich_click as rich_config
@@ -97,7 +97,7 @@ def _restore_rich_click_options(snapshot: RichClickSnapshot) -> None:
97
97
 
98
98
 
99
99
  @contextmanager
100
- def _temporary_rich_click_configuration() -> Iterator[None]: # pyright: ignore[reportUnusedFunction]
100
+ def _temporary_rich_click_configuration() -> Generator[None]: # pyright: ignore[reportUnusedFunction]
101
101
  """Apply plain-output safeguards and restore rich-click globals afterwards."""
102
102
 
103
103
  snapshot = _snapshot_rich_click_options()
@@ -20,7 +20,7 @@ System Integration:
20
20
 
21
21
  from __future__ import annotations
22
22
 
23
- from collections.abc import Iterator, Mapping
23
+ from collections.abc import Generator, Mapping
24
24
  from contextlib import contextmanager
25
25
  from dataclasses import dataclass, fields
26
26
  from enum import Enum
@@ -156,7 +156,7 @@ def reset_config() -> None:
156
156
 
157
157
 
158
158
  @contextmanager
159
- def config_overrides(**overrides: object) -> Iterator[_Config]:
159
+ def config_overrides(**overrides: object) -> Generator[_Config]:
160
160
  """Snapshot configuration state and optionally apply temporary overrides."""
161
161
 
162
162
  _reject_unknown_fields(overrides)
@@ -1,84 +0,0 @@
1
- Test, Fix, Bump, Push — full release pipeline.
2
-
3
- Execute the following steps sequentially. Do NOT skip steps. Stop and ask the user if any decision requires human judgement.
4
-
5
- ---
6
-
7
- ## Step 1 — Run Tests
8
-
9
- Run `make test` and capture the full output.
10
-
11
- ## Step 2 — Fix All Errors
12
-
13
- If `make test` failed:
14
- - Analyze every error in the output (lint, type-check, unit tests, shellcheck, etc.).
15
- - Fix all errors in the source code.
16
- - Re-run `make test` to confirm all errors are resolved.
17
- - Repeat until `make test` passes with zero failures.
18
-
19
- If `make test` passed, proceed to the next step.
20
-
21
- ## Step 3 — Determine Semver Bump Level
22
-
23
- Analyze all changes since the last released version:
24
- - Run `git log $(git describe --tags --abbrev=0)..HEAD --oneline` to list commits since the last tag.
25
- - Run `git diff $(git describe --tags --abbrev=0)..HEAD --stat` to see which files changed.
26
- - Apply semver rules:
27
- - **major** — breaking API changes, removed public functions/classes, changed signatures
28
- - **minor** — new features, new public API, new modules, backward-compatible additions
29
- - **patch** — bug fixes, documentation, internal refactors, dependency updates, CI/CD changes
30
- - Present your reasoning and recommended bump level to the user for confirmation before proceeding.
31
-
32
- ## Step 4 — Bump Version
33
-
34
- Run the appropriate command based on the confirmed semver level:
35
- - `make bump-patch` for patch
36
- - `make bump-minor` for minor
37
- - `make bump-major` for major
38
-
39
- ## Step 5 — Update Changelog
40
-
41
- Update `CHANGELOG.md` with the important changes since the last version:
42
- - Group changes under the new version heading with the current date.
43
- - Categorize entries (Added, Changed, Fixed, Removed, etc.) following Keep a Changelog format.
44
- - Be concise but cover all user-visible and developer-visible changes.
45
-
46
- ## Step 6 — Create Commit Message
47
-
48
- Compose a meaningful commit message that:
49
- - Summarizes the version bump and key changes.
50
- - References the new version number.
51
- - Follows conventional commit style if the project uses it.
52
-
53
- Present the commit message to the user for approval.
54
-
55
- ## Step 7 — Push
56
-
57
- Run `make push <approved commit message>` to run tests, commit, and push to the remote.
58
-
59
- ## Step 8 — Monitor GitHub CI
60
-
61
- After pushing:
62
- - Run `gh run list --limit 1` to find the latest workflow run.
63
- - Run `gh run watch <run-id>` to monitor it until completion.
64
- - If the run **succeeds**, proceed to Step 9.
65
- - If the run **fails**:
66
- - Run `gh run view <run-id> --log-failed` to get failure details.
67
- - Fix all errors in the source code.
68
- - Go back to **Step 5** (update changelog if the fix is meaningful, re-commit, re-push).
69
-
70
- ## Step 9 — Release
71
-
72
- Once GitHub CI is green:
73
- - Run `make release` to create the version tag and GitHub release.
74
-
75
- ## Step 10 — Monitor Release CI
76
-
77
- After releasing:
78
- - Run `gh run list --limit 1` to find the release workflow run.
79
- - Run `gh run watch <run-id>` to monitor it until completion.
80
- - If the run **succeeds**, report the release URL and confirm completion.
81
- - If the run **fails**:
82
- - Run `gh run view <run-id> --log-failed` to get failure details.
83
- - Fix all errors in the source code.
84
- - Go back to **Step 5** (update changelog, re-commit, re-push, re-release).
@@ -1,164 +0,0 @@
1
- # Claude Code Guidelines for lib_cli_exit_tools
2
-
3
- ## Session Initialization
4
-
5
- When starting a new session, read and apply the following system prompt files from `/media/srv-main-softdev/projects/softwarestack/systemprompts`:
6
-
7
- ### Core Guidelines (Always Apply)
8
- - `core_programming_solid.md`
9
-
10
- ### Bash-Specific Guidelines
11
- When working with Bash scripts:
12
- - `core_programming_solid.md`
13
- - `bash_clean_architecture.md`
14
- - `bash_clean_code.md`
15
- - `bash_small_functions.md`
16
-
17
- ### Python-Specific Guidelines
18
- When working with Python code:
19
- - `core_programming_solid.md`
20
- - `python_solid_architecture_enforcer.md`
21
- - use skill `bx-python-clean-architecture`
22
- - `python_clean_code.md`
23
- - `python_small_functions_style.md`
24
- - use skill `bx-python-libraries-to-use`
25
- - `python_data_architecture_enforcement.md`
26
-
27
- ### Additional Guidelines
28
- - `self_documenting.md`
29
- - `self_documenting_template.md`
30
- - `python_jupyter_notebooks.md`
31
- - `python_testing.md`
32
-
33
- ## Project Structure
34
-
35
- ```
36
- lib_cli_exit_tools/
37
- ├── .github/
38
- │ └── workflows/ # GitHub Actions CI/CD workflows
39
- ├── .devcontainer/ # Dev container configuration
40
- ├── docs/ # Project documentation
41
- │ └── system-design/ # System design documents
42
- ├── notebooks/ # Jupyter notebooks for experiments
43
- ├── scripts/ # Build and automation scripts
44
- │ ├── __init__.py # Package marker
45
- │ ├── __main__.py # Module entry point
46
- │ ├── _utils.py # Shared utilities
47
- │ ├── build.py # Build wheel/sdist
48
- │ ├── bump.py # Version bump (generic)
49
- │ ├── bump_major.py # Bump major version
50
- │ ├── bump_minor.py # Bump minor version
51
- │ ├── bump_patch.py # Bump patch version
52
- │ ├── bump_version.py # Version bump utilities
53
- │ ├── clean.py # Clean build artifacts
54
- │ ├── cli.py # CLI for scripts
55
- │ ├── dependencies.py # Dependency management
56
- │ ├── dev.py # Development install
57
- │ ├── help.py # Show help
58
- │ ├── install.py # Install package
59
- │ ├── menu.py # Interactive TUI menu
60
- │ ├── push.py # Git push
61
- │ ├── release.py # Create releases
62
- │ ├── run_cli.py # Run CLI
63
- │ ├── target_metadata.py # Metadata generation
64
- │ ├── test.py # Run tests with coverage
65
- │ ├── toml_config.py # TOML configuration utilities
66
- │ └── version_current.py # Print current version
67
- ├── src/
68
- │ └── lib_cli_exit_tools/ # Main Python package
69
- │ ├── __init__.py # Package initialization
70
- │ ├── __init__conf__.py # Configuration constants
71
- │ ├── __main__.py # CLI entry point
72
- │ ├── cli.py # CLI implementation
73
- │ ├── lib_cli_exit_tools.py # Core library functions
74
- │ ├── py.typed # PEP 561 marker
75
- │ ├── adapters/ # Adapter layer
76
- │ │ └── signals.py # Signal handling adapters
77
- │ ├── application/ # Application layer
78
- │ │ └── runner.py # Application runner
79
- │ └── core/ # Core domain layer
80
- │ ├── configuration.py # Configuration management
81
- │ └── exit_codes.py # Exit code definitions
82
- ├── tests/ # Test suite
83
- ├── .env.example # Example environment variables
84
- ├── CLAUDE.md # Claude Code guidelines (this file)
85
- ├── CHANGELOG.md # Version history
86
- ├── CONTRIBUTING.md # Contribution guidelines
87
- ├── DEVELOPMENT.md # Development setup guide
88
- ├── INSTALL.md # Installation instructions
89
- ├── LICENSE # MIT License
90
- ├── Makefile # Make targets for common tasks
91
- ├── pyproject.toml # Project metadata & dependencies
92
- ├── codecov.yml # Codecov configuration
93
- └── README.md # Project overview
94
- ```
95
-
96
- ## Versioning & Releases
97
-
98
- - **Single Source of Truth**: Package version is in `pyproject.toml` (`[project].version`)
99
- - **Version Bumps**: update `pyproject.toml`, `CHANGELOG.md` and update the constants in `src/lib_cli_exit_tools/__init__conf__.py` according to `pyproject.toml`
100
- - Automation rewrites `src/lib_cli_exit_tools/__init__conf__.py` from `pyproject.toml`, so runtime code imports generated constants instead of querying `importlib.metadata`.
101
- - After updating project metadata (version, summary, URLs, authors) run `make test` (or `python -m scripts.test`) to regenerate the metadata module before committing.
102
- - **Release Tags**: Format is `vX.Y.Z` (push tags for CI to build and publish)
103
-
104
- ## Common Make Targets
105
-
106
- | Target | Description |
107
- |-------------------|---------------------------------------------------------------------------------|
108
- | `build` | Build wheel/sdist artifacts |
109
- | `bump` | Bump version (VERSION=X.Y.Z or PART=major\|minor\|patch) and update changelog |
110
- | `bump-major` | Increment major version ((X+1).0.0) |
111
- | `bump-minor` | Increment minor version (X.Y.Z → X.(Y+1).0) |
112
- | `bump-patch` | Increment patch version (X.Y.Z → X.Y.(Z+1)) |
113
- | `clean` | Remove caches, coverage, and build artifacts (includes `dist/` and `build/`) |
114
- | `dev` | Install package with dev extras |
115
- | `help` | Show make targets |
116
- | `install` | Editable install |
117
- | `menu` | Interactive TUI menu |
118
- | `push` | Commit changes and push to GitHub (no CI monitoring) |
119
- | `release` | Tag vX.Y.Z, push, sync packaging, run gh release if available |
120
- | `run` | Run module entry (`python -m ... --help`) |
121
- | `test` | Lint, format, type-check, run tests with coverage, upload to Codecov |
122
- | `version-current` | Print current version from `pyproject.toml` |
123
-
124
- ## Coding Style & Naming Conventions
125
-
126
- Follow the guidelines in `python_clean_code.md` for all Python code.
127
-
128
- ## Architecture Overview
129
-
130
- This library follows Clean Architecture with three layers:
131
- - **core/**: Domain layer with exit codes and configuration (no external dependencies)
132
- - **application/**: Application services and runners
133
- - **adapters/**: External interfaces (signal handling)
134
-
135
- Import rules (enforced by import-linter):
136
- - `core` cannot import from `application`, `adapters`, or `cli`
137
- - `application` cannot import from `cli`
138
-
139
- Apply principles using skill `bx-python-clean-architecture` when designing and implementing features.
140
-
141
- ## Security & Configuration
142
-
143
- - `.env` files are for local tooling only (CodeCov tokens, etc.)
144
- - **NEVER** commit secrets to version control
145
- - Rich logging should sanitize payloads before rendering
146
-
147
- ## Commit & Push Policy
148
-
149
- ### Pre-Push Requirements
150
- - **Always run `make test` before pushing** to avoid lint/test breakage
151
- - Ensure all tests pass and code is properly formatted
152
-
153
- ### Post-Push Monitoring
154
- - Monitor GitHub Actions for errors after pushing
155
- - Attempt to correct any CI/CD errors that appear
156
-
157
- ## Claude Code Workflow
158
-
159
- When working on this project:
160
- 1. Read relevant system prompts at session start
161
- 2. Apply appropriate coding guidelines based on file type
162
- 3. Run `make test` before commits
163
- 4. Follow versioning guidelines for releases
164
- 5. Monitor CI after pushing changes