shellscripts 0.24.1__tar.gz → 0.25.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 (65) hide show
  1. {shellscripts-0.24.1 → shellscripts-0.25.1}/PKG-INFO +22 -23
  2. {shellscripts-0.24.1 → shellscripts-0.25.1}/README.md +21 -22
  3. {shellscripts-0.24.1 → shellscripts-0.25.1}/pyproject.toml +1 -1
  4. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/__init__.py +1 -1
  5. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/__init__.py +1 -1
  6. shellscripts-0.25.1/src/shell_scripts/commands/agy.py +81 -0
  7. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/config.py +2 -2
  8. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/core.py +38 -13
  9. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/utils.py +1 -1
  10. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shellscripts.egg-info/PKG-INFO +22 -23
  11. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shellscripts.egg-info/SOURCES.txt +3 -3
  12. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_014_pypi_version_source.py +171 -11
  13. shellscripts-0.25.1/tests/test_tst_017_agy_command.py +135 -0
  14. shellscripts-0.24.1/src/shell_scripts/commands/ai_install.py +0 -453
  15. shellscripts-0.24.1/tests/test_tst_003_ai_install.py +0 -775
  16. {shellscripts-0.24.1 → shellscripts-0.25.1}/LICENSE +0 -0
  17. {shellscripts-0.24.1 → shellscripts-0.25.1}/setup.cfg +0 -0
  18. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/__main__.py +0 -0
  19. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/_dc_common.py +0 -0
  20. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/bin_links.py +0 -0
  21. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/claude.py +0 -0
  22. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/clean.py +0 -0
  23. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/codex.py +0 -0
  24. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/copilot.py +0 -0
  25. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/dicom2jpg.py +0 -0
  26. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/dicomviewer.py +0 -0
  27. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/diff_cmd.py +0 -0
  28. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/doxygen_cmd.py +0 -0
  29. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/edit_cmd.py +0 -0
  30. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/gemini.py +0 -0
  31. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/kiro.py +0 -0
  32. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/opencode.py +0 -0
  33. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_crop.py +0 -0
  34. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_merge.py +0 -0
  35. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_split_by_format.py +0 -0
  36. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_split_by_toc.py +0 -0
  37. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_tiler_090.py +0 -0
  38. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_tiler_100.py +0 -0
  39. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pdf_toc_clean.py +0 -0
  40. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/pi.py +0 -0
  41. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/req_cmd.py +0 -0
  42. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/tests_cmd.py +0 -0
  43. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/ubuntu_dark_theme.py +0 -0
  44. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/venv_cmd.py +0 -0
  45. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/video2h264.py +0 -0
  46. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/video2h265.py +0 -0
  47. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/view_cmd.py +0 -0
  48. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/vscode_cmd.py +0 -0
  49. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/commands/vsinsider_cmd.py +0 -0
  50. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shell_scripts/version_check.py +0 -0
  51. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shellscripts.egg-info/dependency_links.txt +0 -0
  52. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shellscripts.egg-info/entry_points.txt +0 -0
  53. {shellscripts-0.24.1 → shellscripts-0.25.1}/src/shellscripts.egg-info/top_level.txt +0 -0
  54. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_001_002_core.py +0 -0
  55. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_004_bin_links_clean.py +0 -0
  56. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_005_cli_launchers.py +0 -0
  57. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_006_dc_common.py +0 -0
  58. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_007_pdf_commands.py +0 -0
  59. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_008_env_commands.py +0 -0
  60. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_010_req_cmd.py +0 -0
  61. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_011_video_commands.py +0 -0
  62. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_012_workflow_runtime.py +0 -0
  63. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_013_release_pypi_gating.py +0 -0
  64. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_015_pre_release_check.py +0 -0
  65. {shellscripts-0.24.1 → shellscripts-0.25.1}/tests/test_tst_016_release_precheck_gating.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: shellscripts
3
- Version: 0.24.1
3
+ Version: 0.25.1
4
4
  Summary: Execute useful shell scripts via an uvx-compatible CLI interface.
5
5
  Author: Francesco Rolando
6
6
  License-Expression: GPL-3.0-only
@@ -31,7 +31,7 @@ Dynamic: license-file
31
31
  > * **No Support or Feature Requests:** Please **do not** open issues, bug reports, or feature requests. They will not be addressed or accepted at this stage of development.
32
32
  > * **No Warranty:** This software is provided **"AS IS"**, without warranty of any kind, express or implied. You may use it strictly for **testing and evaluation purposes** at your own sole risk.
33
33
 
34
- # s/shellScripts (0.24.1)
34
+ # s/shellScripts (0.25.1)
35
35
 
36
36
  <p align="center">
37
37
  <img src="https://img.shields.io/badge/python-3.11%2B-3776AB?style=flat-square&logo=python&logoColor=white" alt="Python 3.11+">
@@ -65,8 +65,7 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
65
65
 
66
66
  ## Feature Highlights
67
67
  - Single CLI entrypoint with command dispatch and grouped built-in help (`shellscripts` and alias `s`).
68
- - AI tooling bootstrap command (`ai-install`) with per-tool selectors for Codex, Copilot, Gemini, OpenCode, Claude, and Kiro.
69
- - Project-context launchers for AI CLIs (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
68
+ - Project-context launchers for AI CLIs (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
70
69
  - PDF workflow commands for crop, merge, split, TOC cleanup, and tiling.
71
70
  - DICOM helpers (`dicom2jpg`, `dicomviewer`) and video transcoders (`video2h264`, `video2h265`).
72
71
  - Project maintenance and automation commands (`req`, `clean`, `venv`, `tests`, `doxygen`, `ubuntu-dark-theme`).
@@ -77,9 +76,8 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
77
76
 
78
77
  - Python `>=3.11`.
79
78
  - Astral `uv` is required for install and runtime flows (`uv tool install`, `uvx`, `uv run`).
80
- - Git is required for commands that enforce repository-root execution (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
79
+ - Git is required for commands that enforce repository-root execution (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
81
80
  - Command-specific external tools are required only for related commands:
82
- - `npm` (and `sudo` on non-Windows) for npm-based `ai-install` targets.
83
81
  - `req` for the `req` command.
84
82
  - `doxygen` (plus optional `make` and `pdflatex`) for `doxygen`.
85
83
  - `gs`, `pdfinfo`, `qpdf`, `pdftk`, `plakativ` for PDF commands.
@@ -108,6 +106,12 @@ Upgrade to the latest published PyPI release:
108
106
  s --upgrade
109
107
  ```
110
108
 
109
+ Force a complete re-download and reinstallation by appending the forced-reinstall options (`--force --reinstall --refresh`) to the configured upgrade command:
110
+
111
+ ```bash
112
+ s --upgrade --force
113
+ ```
114
+
111
115
 
112
116
  ### Run Without Installing (uvx)
113
117
 
@@ -147,6 +151,12 @@ s --upgrade --dev
147
151
  s --upgrade --develop
148
152
  ```
149
153
 
154
+ Add `--force` to force a complete re-download and reinstallation of the tagged release:
155
+
156
+ ```bash
157
+ s --upgrade --develop --force
158
+ ```
159
+
150
160
 
151
161
  ## Management Commands
152
162
 
@@ -163,6 +173,7 @@ Built-in management flags:
163
173
  - `--help` : show full help or command help (`shellscripts --help <command>`).
164
174
  - `--version` / `--ver` : print the installed version plus the latest versions available on PyPI and GitHub.
165
175
  - `--upgrade` : run the configured upgrade command automatically on Linux (installs the latest PyPI release by default), otherwise print the manual command.
176
+ - `--upgrade --force` : force download and complete reinstallation by appending `--force --reinstall --refresh` to the `--upgrade` or `--upgrade --dev`/`--upgrade --develop` command.
166
177
  - `--upgrade --dev` / `--upgrade --develop` : upgrade from the latest tagged GitHub release instead of PyPI, regardless of its source branch.
167
178
  - `--uninstall` : run configured uninstall command automatically on Linux, otherwise print the manual command.
168
179
  - `--write-config` : write the default runtime configuration file.
@@ -200,14 +211,14 @@ Top-level configuration keys:
200
211
 
201
212
  | Command | Purpose |
202
213
  |---|---|
203
- | `ai-install` | Install AI CLIs (all or selected tools). |
214
+ | `agy` | Launch Antigravity CLI in project context (YOLO mode, pass-through args). |
204
215
  | `claude` | Launch Claude CLI in project context. |
205
216
  | `codex` | Launch Codex CLI in project context with auth sync and `CODEX_HOME`. |
206
217
  | `copilot` | Launch Copilot CLI in project context. |
207
218
  | `gemini` | Launch Gemini CLI in project context. |
208
219
  | `kiro` | Launch Kiro CLI in project context. |
209
220
  | `opencode` | Launch OpenCode CLI in project context. |
210
- | `pi` | Launch pi.dev CLI in project context (adds default `--tools` when missing). |
221
+ | `pi` | Launch pi.dev CLI in project context (forwards all arguments unchanged). |
211
222
  | `clean` | Find and delete cache directories under the project root (or a passed directory). |
212
223
  | `req` | Run useReq bootstrap on current directory, first-level dirs, or recursively. |
213
224
  | `venv` | Recreate `.venv` and install `requirements.txt` if present. |
@@ -233,25 +244,13 @@ Top-level configuration keys:
233
244
 
234
245
  ### Selected Usage Examples
235
246
 
236
- Install all AI CLIs (default behavior):
237
-
238
- ```bash
239
- s ai-install
240
- ```
241
-
242
- Install only selected AI tools:
243
-
244
- ```bash
245
- s ai-install --codex --gemini --claude
246
- ```
247
-
248
- Run pi.dev with default tools injected automatically:
247
+ Launch Antigravity CLI in YOLO mode (command help lists the available AI CLIs in alphabetical order):
249
248
 
250
249
  ```bash
251
- s pi
250
+ s agy
252
251
  ```
253
252
 
254
- Override pi tools explicitly:
253
+ Run pi.dev CLI forwarding all arguments unchanged (no implicit option injection):
255
254
 
256
255
  ```bash
257
256
  s pi --tools read,bash,grep,find
@@ -10,7 +10,7 @@
10
10
  > * **No Support or Feature Requests:** Please **do not** open issues, bug reports, or feature requests. They will not be addressed or accepted at this stage of development.
11
11
  > * **No Warranty:** This software is provided **"AS IS"**, without warranty of any kind, express or implied. You may use it strictly for **testing and evaluation purposes** at your own sole risk.
12
12
 
13
- # s/shellScripts (0.24.1)
13
+ # s/shellScripts (0.25.1)
14
14
 
15
15
  <p align="center">
16
16
  <img src="https://img.shields.io/badge/python-3.11%2B-3776AB?style=flat-square&logo=python&logoColor=white" alt="Python 3.11+">
@@ -44,8 +44,7 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
44
44
 
45
45
  ## Feature Highlights
46
46
  - Single CLI entrypoint with command dispatch and grouped built-in help (`shellscripts` and alias `s`).
47
- - AI tooling bootstrap command (`ai-install`) with per-tool selectors for Codex, Copilot, Gemini, OpenCode, Claude, and Kiro.
48
- - Project-context launchers for AI CLIs (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
47
+ - Project-context launchers for AI CLIs (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
49
48
  - PDF workflow commands for crop, merge, split, TOC cleanup, and tiling.
50
49
  - DICOM helpers (`dicom2jpg`, `dicomviewer`) and video transcoders (`video2h264`, `video2h265`).
51
50
  - Project maintenance and automation commands (`req`, `clean`, `venv`, `tests`, `doxygen`, `ubuntu-dark-theme`).
@@ -56,9 +55,8 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
56
55
 
57
56
  - Python `>=3.11`.
58
57
  - Astral `uv` is required for install and runtime flows (`uv tool install`, `uvx`, `uv run`).
59
- - Git is required for commands that enforce repository-root execution (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
58
+ - Git is required for commands that enforce repository-root execution (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
60
59
  - Command-specific external tools are required only for related commands:
61
- - `npm` (and `sudo` on non-Windows) for npm-based `ai-install` targets.
62
60
  - `req` for the `req` command.
63
61
  - `doxygen` (plus optional `make` and `pdflatex`) for `doxygen`.
64
62
  - `gs`, `pdfinfo`, `qpdf`, `pdftk`, `plakativ` for PDF commands.
@@ -87,6 +85,12 @@ Upgrade to the latest published PyPI release:
87
85
  s --upgrade
88
86
  ```
89
87
 
88
+ Force a complete re-download and reinstallation by appending the forced-reinstall options (`--force --reinstall --refresh`) to the configured upgrade command:
89
+
90
+ ```bash
91
+ s --upgrade --force
92
+ ```
93
+
90
94
 
91
95
  ### Run Without Installing (uvx)
92
96
 
@@ -126,6 +130,12 @@ s --upgrade --dev
126
130
  s --upgrade --develop
127
131
  ```
128
132
 
133
+ Add `--force` to force a complete re-download and reinstallation of the tagged release:
134
+
135
+ ```bash
136
+ s --upgrade --develop --force
137
+ ```
138
+
129
139
 
130
140
  ## Management Commands
131
141
 
@@ -142,6 +152,7 @@ Built-in management flags:
142
152
  - `--help` : show full help or command help (`shellscripts --help <command>`).
143
153
  - `--version` / `--ver` : print the installed version plus the latest versions available on PyPI and GitHub.
144
154
  - `--upgrade` : run the configured upgrade command automatically on Linux (installs the latest PyPI release by default), otherwise print the manual command.
155
+ - `--upgrade --force` : force download and complete reinstallation by appending `--force --reinstall --refresh` to the `--upgrade` or `--upgrade --dev`/`--upgrade --develop` command.
145
156
  - `--upgrade --dev` / `--upgrade --develop` : upgrade from the latest tagged GitHub release instead of PyPI, regardless of its source branch.
146
157
  - `--uninstall` : run configured uninstall command automatically on Linux, otherwise print the manual command.
147
158
  - `--write-config` : write the default runtime configuration file.
@@ -179,14 +190,14 @@ Top-level configuration keys:
179
190
 
180
191
  | Command | Purpose |
181
192
  |---|---|
182
- | `ai-install` | Install AI CLIs (all or selected tools). |
193
+ | `agy` | Launch Antigravity CLI in project context (YOLO mode, pass-through args). |
183
194
  | `claude` | Launch Claude CLI in project context. |
184
195
  | `codex` | Launch Codex CLI in project context with auth sync and `CODEX_HOME`. |
185
196
  | `copilot` | Launch Copilot CLI in project context. |
186
197
  | `gemini` | Launch Gemini CLI in project context. |
187
198
  | `kiro` | Launch Kiro CLI in project context. |
188
199
  | `opencode` | Launch OpenCode CLI in project context. |
189
- | `pi` | Launch pi.dev CLI in project context (adds default `--tools` when missing). |
200
+ | `pi` | Launch pi.dev CLI in project context (forwards all arguments unchanged). |
190
201
  | `clean` | Find and delete cache directories under the project root (or a passed directory). |
191
202
  | `req` | Run useReq bootstrap on current directory, first-level dirs, or recursively. |
192
203
  | `venv` | Recreate `.venv` and install `requirements.txt` if present. |
@@ -212,25 +223,13 @@ Top-level configuration keys:
212
223
 
213
224
  ### Selected Usage Examples
214
225
 
215
- Install all AI CLIs (default behavior):
216
-
217
- ```bash
218
- s ai-install
219
- ```
220
-
221
- Install only selected AI tools:
222
-
223
- ```bash
224
- s ai-install --codex --gemini --claude
225
- ```
226
-
227
- Run pi.dev with default tools injected automatically:
226
+ Launch Antigravity CLI in YOLO mode (command help lists the available AI CLIs in alphabetical order):
228
227
 
229
228
  ```bash
230
- s pi
229
+ s agy
231
230
  ```
232
231
 
233
- Override pi tools explicitly:
232
+ Run pi.dev CLI forwarding all arguments unchanged (no implicit option injection):
234
233
 
235
234
  ```bash
236
235
  s pi --tools read,bash,grep,find
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "shellscripts"
7
- version = "0.24.1"
7
+ version = "0.25.1"
8
8
  description = "Execute useful shell scripts via an uvx-compatible CLI interface."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.11"
@@ -1,4 +1,4 @@
1
- __version__ = "0.24.1"
1
+ __version__ = "0.25.1"
2
2
 
3
3
  from .core import main # noqa: F401
4
4
 
@@ -15,7 +15,7 @@ from types import ModuleType
15
15
  # Removing an entry removes command discoverability and dispatch reachability.
16
16
  # @satisfies PRJ-003, DES-001
17
17
  _COMMAND_MODULES = {
18
- "ai-install": "shell_scripts.commands.ai_install",
18
+ "agy": "shell_scripts.commands.agy",
19
19
  "clean": "shell_scripts.commands.clean",
20
20
  "claude": "shell_scripts.commands.claude",
21
21
  "codex": "shell_scripts.commands.codex",
@@ -0,0 +1,81 @@
1
+ #!/usr/bin/env python3
2
+ """@brief Antigravity CLI launcher in project context.
3
+
4
+ @details Ensures project-root prerequisite and executable availability before
5
+ blocking subprocess invocation of `agy` in YOLO mode
6
+ (`--dangerously-skip-permissions`); inline help lists the registered AI CLI
7
+ launch commands in alphabetical order.
8
+ @satisfies REQ-085, REQ-086, REQ-055, REQ-056, REQ-064
9
+ """
10
+
11
+ import subprocess
12
+
13
+ from shell_scripts.utils import require_project_root, require_commands
14
+
15
+ ## @var PROGRAM
16
+ # @brief Base CLI program name used in help output.
17
+ # @details Constant identifier for usage-line rendering in command help.
18
+ PROGRAM = "shellscripts"
19
+ ## @var DESCRIPTION
20
+ # @brief One-line command description for dispatcher help surfaces.
21
+ # @details Exposed by command registry introspection (`get_all_commands`).
22
+ DESCRIPTION = "Launch Antigravity CLI in the project context."
23
+ ## @var AI_CLI_COMMANDS
24
+ # @brief Alphabetically sorted AI CLI launch command tokens rendered in inline help.
25
+ # @details Derived through `sorted()` at import time so token-set edits preserve
26
+ # the REQ-086 alphabetical rendering contract; contains launcher commands only
27
+ # and excludes installer command tokens.
28
+ # @satisfies REQ-086
29
+ AI_CLI_COMMANDS = tuple(sorted((
30
+ "agy",
31
+ "claude",
32
+ "codex",
33
+ "copilot",
34
+ "gemini",
35
+ "kiro",
36
+ "opencode",
37
+ "pi",
38
+ )))
39
+
40
+
41
+ def print_help(version):
42
+ """@brief Print command-specific help for `agy`.
43
+
44
+ @details Emits usage and pass-through argument behavior, then renders the
45
+ AI CLI launch command tokens from `AI_CLI_COMMANDS`, one per line, in
46
+ ascending alphabetical order; does not mutate process state.
47
+ Time complexity O(n) over registered AI CLI token count.
48
+ @param version {str} CLI version string propagated by dispatcher.
49
+ @return {None} Writes help text to stdout.
50
+ @satisfies DES-008, REQ-086
51
+ """
52
+
53
+ print(f"Usage: {PROGRAM} agy [args...] ({version})")
54
+ print()
55
+ print("agy options:")
56
+ print(" All arguments are passed through to the Antigravity CLI.")
57
+ print(" --help - Show this help message.")
58
+ print()
59
+ print("Available AI CLIs (alphabetical order):")
60
+ for command_token in AI_CLI_COMMANDS:
61
+ print(f" {command_token}")
62
+
63
+
64
+ def run(args):
65
+ """@brief Launch Antigravity CLI in YOLO mode after executable validation.
66
+
67
+ @details Resolves project root, builds the fixed command vector
68
+ `[agy, --dangerously-skip-permissions] + args`, resolves the executable
69
+ path via `require_commands`, then executes it through blocking
70
+ `subprocess.run` with inherited stdio. Time complexity O(n) over forwarded
71
+ argument count.
72
+ @param args {list[str]} Additional CLI args forwarded to Antigravity.
73
+ @return {int} Child process return code.
74
+ @satisfies REQ-085, REQ-055, REQ-056, REQ-064
75
+ """
76
+
77
+ require_project_root()
78
+ cmd = ["agy", "--dangerously-skip-permissions"] + args
79
+ cmd[0] = require_commands(cmd[0])
80
+ result = subprocess.run(cmd)
81
+ return result.returncode
@@ -25,9 +25,9 @@ from shell_scripts.utils import print_warn
25
25
  # @satisfies DES-011, DES-012
26
26
  DEFAULT_RUNTIME_CONFIG: dict[str, Any] = {
27
27
  "management": {
28
- "upgrade": "uv tool install shellscripts --force",
28
+ "upgrade": "uv tool install shellscripts",
29
29
  "upgrade_develop": (
30
- "uv tool install shellscripts --force "
30
+ "uv tool install shellscripts "
31
31
  "--from git+https://github.com/Ogekuri/shellScripts.git@{tag}"
32
32
  ),
33
33
  "uninstall": "uv tool uninstall shellscripts",
@@ -3,9 +3,10 @@
3
3
 
4
4
  @details Provides global help rendering, management command execution
5
5
  (`--version`, `--ver`, `--upgrade`, `--uninstall`, `--write-config`,
6
- `--develop`/`--dev` upgrade selector), runtime
7
- configuration bootstrap, and subcommand delegation to lazily imported modules.
8
- @satisfies PRJ-001, PRJ-002, PRJ-003, REQ-001, REQ-002, REQ-003, REQ-004, REQ-005, REQ-045, REQ-046, REQ-048, REQ-049, REQ-050, REQ-051, REQ-052, REQ-053, REQ-054, REQ-056, REQ-064, REQ-065, REQ-066, REQ-068, REQ-069, REQ-075, REQ-076, REQ-077, REQ-078
6
+ `--develop`/`--dev` upgrade selector, `--force` forced-reinstall selector),
7
+ runtime configuration bootstrap, and subcommand delegation to lazily imported
8
+ modules.
9
+ @satisfies PRJ-001, PRJ-002, PRJ-003, REQ-001, REQ-002, REQ-003, REQ-004, REQ-005, REQ-045, REQ-046, REQ-048, REQ-049, REQ-050, REQ-051, REQ-052, REQ-053, REQ-054, REQ-056, REQ-064, REQ-065, REQ-066, REQ-068, REQ-069, REQ-075, REQ-076, REQ-077, REQ-078, REQ-087, REQ-088, REQ-089, REQ-090
9
10
  """
10
11
 
11
12
  import sys
@@ -37,6 +38,14 @@ PROGRAM = "shellscripts"
37
38
  # @satisfies REQ-066
38
39
  HELP_COMMAND_COLUMN_WIDTH = 16
39
40
 
41
+ ## @var FORCED_REINSTALL_OPTIONS
42
+ # @brief Option suffix appended to upgrade commands when `--force` is active.
43
+ # @details Standard forced-reinstall options for `uv tool install`: replace
44
+ # the installed tool entry, reinstall the package, and refresh cached remote
45
+ # metadata so the upgrade performs a full re-download and reinstallation.
46
+ # @satisfies REQ-088, REQ-089
47
+ FORCED_REINSTALL_OPTIONS = "--force --reinstall --refresh"
48
+
40
49
  ## @var HELP_SECTION_COMMANDS
41
50
  # @brief Ordered command groups for global help rendering.
42
51
  # @details Defines deterministic section order and command-token order used by
@@ -67,7 +76,7 @@ HELP_SECTION_COMMANDS = (
67
76
  (
68
77
  "AI Commands",
69
78
  (
70
- "ai-install",
79
+ "agy",
71
80
  "claude",
72
81
  "codex",
73
82
  "copilot",
@@ -142,6 +151,10 @@ def print_help(command_name=None):
142
151
  " --dev - With --upgrade: upgrade from the latest GitHub release tag"
143
152
  )
144
153
  print(" instead of PyPI (alias: --develop).")
154
+ print(
155
+ " --force - With --upgrade: force download and complete reinstallation"
156
+ )
157
+ print(" (appends --force --reinstall --refresh).")
145
158
  print(
146
159
  f" --uninstall - Uninstall {PROGRAM} on Linux; print manual command elsewhere."
147
160
  )
@@ -181,18 +194,21 @@ def _build_develop_upgrade_command(latest_tag: str) -> str:
181
194
  return template.replace("{tag}", latest_tag)
182
195
 
183
196
 
184
- def do_upgrade(develop: bool = False) -> int:
197
+ def do_upgrade(develop: bool = False, force: bool = False) -> int:
185
198
  """@brief Execute Linux-only upgrade command resolved from runtime config.
186
199
 
187
200
  @details Reads management command string from runtime config key
188
201
  `management.upgrade` (PyPI default) or, when `develop` is set, resolves
189
202
  the latest GitHub release tag and composes the tag-pinned upgrade command;
190
- executes it on Linux via shell invocation and prints the manual fallback
191
- command on non-Linux systems.
192
- @param develop {bool} Force upgrade from the latest GitHub release tag.
203
+ appends ` --force --reinstall --refresh` to the resolved command when
204
+ `force` is set; executes the composed command on Linux via shell
205
+ invocation and prints the manual fallback command on non-Linux systems.
206
+ Complexity O(n) over the composed command string length.
207
+ @param develop {bool} Select upgrade from the latest GitHub release tag.
208
+ @param force {bool} Append forced-reinstall options to the upgrade command.
193
209
  @return {int} `1` when develop tag resolution fails; subprocess return code
194
210
  on Linux; `0` on non-Linux fallback.
195
- @satisfies REQ-004, REQ-076, REQ-078, REQ-045, REQ-056
211
+ @satisfies REQ-004, REQ-076, REQ-078, REQ-087, REQ-088, REQ-089, REQ-045, REQ-056
196
212
  """
197
213
 
198
214
  if develop:
@@ -204,6 +220,8 @@ def do_upgrade(develop: bool = False) -> int:
204
220
  install_cmd = _build_develop_upgrade_command(latest_tag)
205
221
  else:
206
222
  install_cmd = get_management_command("upgrade")
223
+ if force:
224
+ install_cmd = f"{install_cmd} {FORCED_REINSTALL_OPTIONS}"
207
225
  if is_linux():
208
226
  require_shell_command_executables(install_cmd)
209
227
  print(f"Upgrading {PROGRAM}...")
@@ -261,12 +279,14 @@ def main():
261
279
  @details Performs runtime OS detection, update check, runtime configuration
262
280
  load, and argument dispatch through management flags (`--version` prints
263
281
  installed plus PyPI/GitHub latest versions; `--upgrade` upgrades from PyPI
264
- or, with `--develop`/`--dev`, from the latest GitHub release tag) and
265
- subcommands, then restores terminal raw/cbreak and disables legacy+xterm
282
+ or, with `--develop`/`--dev`, from the latest GitHub release tag; `--force`
283
+ appends forced-reinstall options to the selected upgrade command; bare
284
+ `--develop`/`--dev`/`--force` selectors are rejected) and subcommands,
285
+ then restores terminal raw/cbreak and disables legacy+xterm
266
286
  mouse-tracking modes (`?9l`, `?1000l`, `?1001l`, `?1002l`, `?1003l`,
267
287
  `?1004l`, `?1005l`, `?1006l`, `?1007l`, `?1015l`, `?1016l`) before exit.
268
288
  @return {int} Process-compatible return code for caller (`sys.exit`).
269
- @satisfies PRJ-001, REQ-001, REQ-002, REQ-003, REQ-004, REQ-005, REQ-045, REQ-046, REQ-047, REQ-048, REQ-049, REQ-050, REQ-051, REQ-052, REQ-053, REQ-054, REQ-064, REQ-065, REQ-066, REQ-068, REQ-069, REQ-075, REQ-076, REQ-077, REQ-078
289
+ @satisfies PRJ-001, REQ-001, REQ-002, REQ-003, REQ-004, REQ-005, REQ-045, REQ-046, REQ-047, REQ-048, REQ-049, REQ-050, REQ-051, REQ-052, REQ-053, REQ-054, REQ-064, REQ-065, REQ-066, REQ-068, REQ-069, REQ-075, REQ-076, REQ-077, REQ-078, REQ-087, REQ-088, REQ-089, REQ-090
270
290
  """
271
291
  saved_tty = capture_terminal_state()
272
292
  try:
@@ -289,12 +309,17 @@ def main():
289
309
 
290
310
  if first_arg == "--upgrade":
291
311
  develop = any(arg in ("--develop", "--dev") for arg in args[1:])
292
- return do_upgrade(develop=develop)
312
+ force = "--force" in args[1:]
313
+ return do_upgrade(develop=develop, force=force)
293
314
 
294
315
  if first_arg in ("--develop", "--dev"):
295
316
  print_error("--develop/--dev must be used together with --upgrade.")
296
317
  return 1
297
318
 
319
+ if first_arg == "--force":
320
+ print_error("--force must be used together with --upgrade.")
321
+ return 1
322
+
298
323
  if first_arg == "--uninstall":
299
324
  return do_uninstall()
300
325
 
@@ -155,7 +155,7 @@ def is_windows():
155
155
 
156
156
  @details Evaluates cached runtime token from `get_runtime_os`.
157
157
  @return {bool} `True` when runtime OS is Windows; otherwise `False`.
158
- @satisfies DES-013, REQ-008, REQ-047
158
+ @satisfies REQ-047
159
159
  """
160
160
 
161
161
  return get_runtime_os() == "windows"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: shellscripts
3
- Version: 0.24.1
3
+ Version: 0.25.1
4
4
  Summary: Execute useful shell scripts via an uvx-compatible CLI interface.
5
5
  Author: Francesco Rolando
6
6
  License-Expression: GPL-3.0-only
@@ -31,7 +31,7 @@ Dynamic: license-file
31
31
  > * **No Support or Feature Requests:** Please **do not** open issues, bug reports, or feature requests. They will not be addressed or accepted at this stage of development.
32
32
  > * **No Warranty:** This software is provided **"AS IS"**, without warranty of any kind, express or implied. You may use it strictly for **testing and evaluation purposes** at your own sole risk.
33
33
 
34
- # s/shellScripts (0.24.1)
34
+ # s/shellScripts (0.25.1)
35
35
 
36
36
  <p align="center">
37
37
  <img src="https://img.shields.io/badge/python-3.11%2B-3776AB?style=flat-square&logo=python&logoColor=white" alt="Python 3.11+">
@@ -65,8 +65,7 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
65
65
 
66
66
  ## Feature Highlights
67
67
  - Single CLI entrypoint with command dispatch and grouped built-in help (`shellscripts` and alias `s`).
68
- - AI tooling bootstrap command (`ai-install`) with per-tool selectors for Codex, Copilot, Gemini, OpenCode, Claude, and Kiro.
69
- - Project-context launchers for AI CLIs (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
68
+ - Project-context launchers for AI CLIs (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`) and IDEs (`vscode`, `vsinsider`).
70
69
  - PDF workflow commands for crop, merge, split, TOC cleanup, and tiling.
71
70
  - DICOM helpers (`dicom2jpg`, `dicomviewer`) and video transcoders (`video2h264`, `video2h265`).
72
71
  - Project maintenance and automation commands (`req`, `clean`, `venv`, `tests`, `doxygen`, `ubuntu-dark-theme`).
@@ -77,9 +76,8 @@ PDF/DICOM utilities, development helpers, and editor integrations, exposed throu
77
76
 
78
77
  - Python `>=3.11`.
79
78
  - Astral `uv` is required for install and runtime flows (`uv tool install`, `uvx`, `uv run`).
80
- - Git is required for commands that enforce repository-root execution (`claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
79
+ - Git is required for commands that enforce repository-root execution (`agy`, `claude`, `codex`, `copilot`, `gemini`, `kiro`, `opencode`, `pi`, `clean`, `venv`, `tests`, `doxygen`, `vscode`, `vsinsider`).
81
80
  - Command-specific external tools are required only for related commands:
82
- - `npm` (and `sudo` on non-Windows) for npm-based `ai-install` targets.
83
81
  - `req` for the `req` command.
84
82
  - `doxygen` (plus optional `make` and `pdflatex`) for `doxygen`.
85
83
  - `gs`, `pdfinfo`, `qpdf`, `pdftk`, `plakativ` for PDF commands.
@@ -108,6 +106,12 @@ Upgrade to the latest published PyPI release:
108
106
  s --upgrade
109
107
  ```
110
108
 
109
+ Force a complete re-download and reinstallation by appending the forced-reinstall options (`--force --reinstall --refresh`) to the configured upgrade command:
110
+
111
+ ```bash
112
+ s --upgrade --force
113
+ ```
114
+
111
115
 
112
116
  ### Run Without Installing (uvx)
113
117
 
@@ -147,6 +151,12 @@ s --upgrade --dev
147
151
  s --upgrade --develop
148
152
  ```
149
153
 
154
+ Add `--force` to force a complete re-download and reinstallation of the tagged release:
155
+
156
+ ```bash
157
+ s --upgrade --develop --force
158
+ ```
159
+
150
160
 
151
161
  ## Management Commands
152
162
 
@@ -163,6 +173,7 @@ Built-in management flags:
163
173
  - `--help` : show full help or command help (`shellscripts --help <command>`).
164
174
  - `--version` / `--ver` : print the installed version plus the latest versions available on PyPI and GitHub.
165
175
  - `--upgrade` : run the configured upgrade command automatically on Linux (installs the latest PyPI release by default), otherwise print the manual command.
176
+ - `--upgrade --force` : force download and complete reinstallation by appending `--force --reinstall --refresh` to the `--upgrade` or `--upgrade --dev`/`--upgrade --develop` command.
166
177
  - `--upgrade --dev` / `--upgrade --develop` : upgrade from the latest tagged GitHub release instead of PyPI, regardless of its source branch.
167
178
  - `--uninstall` : run configured uninstall command automatically on Linux, otherwise print the manual command.
168
179
  - `--write-config` : write the default runtime configuration file.
@@ -200,14 +211,14 @@ Top-level configuration keys:
200
211
 
201
212
  | Command | Purpose |
202
213
  |---|---|
203
- | `ai-install` | Install AI CLIs (all or selected tools). |
214
+ | `agy` | Launch Antigravity CLI in project context (YOLO mode, pass-through args). |
204
215
  | `claude` | Launch Claude CLI in project context. |
205
216
  | `codex` | Launch Codex CLI in project context with auth sync and `CODEX_HOME`. |
206
217
  | `copilot` | Launch Copilot CLI in project context. |
207
218
  | `gemini` | Launch Gemini CLI in project context. |
208
219
  | `kiro` | Launch Kiro CLI in project context. |
209
220
  | `opencode` | Launch OpenCode CLI in project context. |
210
- | `pi` | Launch pi.dev CLI in project context (adds default `--tools` when missing). |
221
+ | `pi` | Launch pi.dev CLI in project context (forwards all arguments unchanged). |
211
222
  | `clean` | Find and delete cache directories under the project root (or a passed directory). |
212
223
  | `req` | Run useReq bootstrap on current directory, first-level dirs, or recursively. |
213
224
  | `venv` | Recreate `.venv` and install `requirements.txt` if present. |
@@ -233,25 +244,13 @@ Top-level configuration keys:
233
244
 
234
245
  ### Selected Usage Examples
235
246
 
236
- Install all AI CLIs (default behavior):
237
-
238
- ```bash
239
- s ai-install
240
- ```
241
-
242
- Install only selected AI tools:
243
-
244
- ```bash
245
- s ai-install --codex --gemini --claude
246
- ```
247
-
248
- Run pi.dev with default tools injected automatically:
247
+ Launch Antigravity CLI in YOLO mode (command help lists the available AI CLIs in alphabetical order):
249
248
 
250
249
  ```bash
251
- s pi
250
+ s agy
252
251
  ```
253
252
 
254
- Override pi tools explicitly:
253
+ Run pi.dev CLI forwarding all arguments unchanged (no implicit option injection):
255
254
 
256
255
  ```bash
257
256
  s pi --tools read,bash,grep,find
@@ -9,7 +9,7 @@ src/shell_scripts/utils.py
9
9
  src/shell_scripts/version_check.py
10
10
  src/shell_scripts/commands/__init__.py
11
11
  src/shell_scripts/commands/_dc_common.py
12
- src/shell_scripts/commands/ai_install.py
12
+ src/shell_scripts/commands/agy.py
13
13
  src/shell_scripts/commands/bin_links.py
14
14
  src/shell_scripts/commands/claude.py
15
15
  src/shell_scripts/commands/clean.py
@@ -46,7 +46,6 @@ src/shellscripts.egg-info/dependency_links.txt
46
46
  src/shellscripts.egg-info/entry_points.txt
47
47
  src/shellscripts.egg-info/top_level.txt
48
48
  tests/test_tst_001_002_core.py
49
- tests/test_tst_003_ai_install.py
50
49
  tests/test_tst_004_bin_links_clean.py
51
50
  tests/test_tst_005_cli_launchers.py
52
51
  tests/test_tst_006_dc_common.py
@@ -58,4 +57,5 @@ tests/test_tst_012_workflow_runtime.py
58
57
  tests/test_tst_013_release_pypi_gating.py
59
58
  tests/test_tst_014_pypi_version_source.py
60
59
  tests/test_tst_015_pre_release_check.py
61
- tests/test_tst_016_release_precheck_gating.py
60
+ tests/test_tst_016_release_precheck_gating.py
61
+ tests/test_tst_017_agy_command.py