fips-agents-cli 0.8.2__tar.gz → 0.9.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.
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/CLAUDE.md +6 -1
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/PKG-INFO +39 -33
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/README.md +38 -32
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/pyproject.toml +1 -1
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/create.py +8 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/patch.py +50 -27
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/patching.py +156 -26
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/project.py +17 -5
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/validation.py +41 -2
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/version.py +1 -1
- fips_agents_cli-0.9.1/tests/test_patch.py +295 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.claude/commands/create-release.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.claude/docs-state.json +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.github/CODEOWNERS +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.github/agents/README.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.github/agents/create-release.agent.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.github/workflows/test.yml +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.github/workflows/workflow.yaml +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/.gitignore +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/LICENSE +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/RELEASE_CHECKLIST.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/docs/PUBLISHING.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/docs/QUICK_START_PUBLISHING.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/docs/README.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/llms.txt +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/AGENT_FRAMEWORK_PLAN.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/GENERATOR_IMPLEMENTATION_PLAN.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/IMPLEMENTATION_SUMMARY.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/MVP-PLAN.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/PLAN.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/PROMPT_ISSUE.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/agent-registry-roadmap.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/agent-template-gaps.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/planning/composable-agent-capabilities.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/research/BAML_RESEARCH_REPORT.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/research/Ignite-CLI-Architecture-Analysis.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/retrospectives/2026-04-06_issue-triage-v0.3.0/RETRO.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/retrospectives/2026-04-10_full-stack-integration/RETRO.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/scripts/README.md +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/scripts/release.sh +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/__init__.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/__main__.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/cli.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/__init__.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/add.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/generate.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/model_car.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/vendor.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/__init__.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/filesystem.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/generators.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/git.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/github.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/__init__.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/conftest.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/fixtures/middleware_template/component.py.j2 +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/fixtures/middleware_template/test.py.j2 +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_create.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_filesystem.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_generate.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_generators.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_github.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_model_car.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_project.py +0 -0
- {fips_agents_cli-0.8.2 → fips_agents_cli-0.9.1}/tests/test_validation.py +0 -0
|
@@ -6,7 +6,12 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
|
|
|
6
6
|
|
|
7
7
|
**fips-agents-cli** is a Python-based CLI tool for scaffolding FIPS-compliant AI agent projects. It scaffolds MCP (Model Context Protocol) servers and AI agent projects from production-ready templates, customizes them for new projects, and prepares them for immediate development use.
|
|
8
8
|
|
|
9
|
-
**Current Status:** Scaffolding commands implemented: `create mcp-server`, `create agent`, `create gateway`, `create ui`, `create sandbox`, `create model-car`. Post-scaffolding commands: `generate` (tool, resource, prompt, middleware), `patch` (check,
|
|
9
|
+
**Current Status:** Scaffolding commands implemented: `create mcp-server`, `create agent`, `create gateway`, `create ui`, `create sandbox`, `create model-car`. Post-scaffolding commands: `generate` (tool, resource, prompt, middleware), `patch` (check, all + type-specific category subcommands — see below), `add` (code-executor), `vendor`. Note: `create workflow` exists in code but is not yet working.
|
|
10
|
+
|
|
11
|
+
The `patch` command is type-aware via `template.type` in `.template-info`:
|
|
12
|
+
- **MCP server** projects expose `patch generators | core | docs | build`.
|
|
13
|
+
- **Agent / workflow** projects expose `patch chart | docs | build | claude`.
|
|
14
|
+
Running an MCP-only subcommand inside an agent project (or vice versa) exits with a clear "available categories" error. `patch check` and `patch all` work for any supported type.
|
|
10
15
|
|
|
11
16
|
## Development Commands
|
|
12
17
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: fips-agents-cli
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.9.1
|
|
4
4
|
Summary: CLI tool for creating and managing FIPS-compliant AI agent projects
|
|
5
5
|
Project-URL: Homepage, https://github.com/fips-agents/fips-agents-cli
|
|
6
6
|
Project-URL: Repository, https://github.com/fips-agents/fips-agents-cli
|
|
@@ -557,7 +557,9 @@ When using `--params` with `generate tool` or `generate prompt`, provide a JSON
|
|
|
557
557
|
|
|
558
558
|
### Patch Commands
|
|
559
559
|
|
|
560
|
-
The `patch` command group updates files in existing
|
|
560
|
+
The `patch` command group updates files in existing projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
|
|
561
|
+
|
|
562
|
+
Supported project types: **MCP server**, **agent**, **workflow**. The available category subcommands depend on the project type — `patch` reads `template.type` from `.template-info` and surfaces a clear error if you run a category that doesn't apply (e.g. `patch generators` inside an agent project).
|
|
561
563
|
|
|
562
564
|
Run these commands from within your project directory.
|
|
563
565
|
|
|
@@ -567,47 +569,35 @@ Run these commands from within your project directory.
|
|
|
567
569
|
fips-agents patch check
|
|
568
570
|
```
|
|
569
571
|
|
|
570
|
-
Check for available template updates. Shows what files have changed in the template since your project was created, organized by category.
|
|
571
|
-
|
|
572
|
-
#### `patch generators`
|
|
573
|
-
|
|
574
|
-
```bash
|
|
575
|
-
fips-agents patch generators [--dry-run]
|
|
576
|
-
```
|
|
577
|
-
|
|
578
|
-
Update code generator templates (Jinja2 templates in `.fips-agents-cli/generators/`).
|
|
572
|
+
Check for available template updates. Shows what files have changed in the template since your project was created, organized by category. Works for any supported project type.
|
|
579
573
|
|
|
580
|
-
#### `patch
|
|
581
|
-
|
|
582
|
-
```bash
|
|
583
|
-
fips-agents patch core [--dry-run]
|
|
584
|
-
```
|
|
585
|
-
|
|
586
|
-
Update core infrastructure files (loaders, server bootstrap).
|
|
587
|
-
|
|
588
|
-
#### `patch docs`
|
|
574
|
+
#### `patch all`
|
|
589
575
|
|
|
590
576
|
```bash
|
|
591
|
-
fips-agents patch
|
|
577
|
+
fips-agents patch all [--dry-run] [--skip-confirmation]
|
|
592
578
|
```
|
|
593
579
|
|
|
594
|
-
Update
|
|
595
|
-
|
|
596
|
-
#### `patch build`
|
|
580
|
+
Update every category that applies to the current project type. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
|
|
597
581
|
|
|
598
|
-
|
|
599
|
-
fips-agents patch build [--dry-run]
|
|
600
|
-
```
|
|
582
|
+
#### MCP server categories
|
|
601
583
|
|
|
602
|
-
|
|
584
|
+
| Subcommand | Patches |
|
|
585
|
+
|----------------------|--------------------------------------------------------------------------|
|
|
586
|
+
| `patch generators` | Jinja2 templates in `.fips-agents-cli/generators/` |
|
|
587
|
+
| `patch core` | Core infrastructure (loaders, server bootstrap) |
|
|
588
|
+
| `patch docs` | Documentation files and examples |
|
|
589
|
+
| `patch build` | Build and deployment files (Makefile, Containerfile) |
|
|
603
590
|
|
|
604
|
-
####
|
|
591
|
+
#### Agent / workflow categories
|
|
605
592
|
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
593
|
+
| Subcommand | Patches |
|
|
594
|
+
|----------------|-------------------------------------------------------------------------------|
|
|
595
|
+
| `patch chart` | Helm chart templates (`chart/templates/**`, `chart/Chart.yaml`) |
|
|
596
|
+
| `patch docs` | `CLAUDE.md`, `AGENTS.md`, `docs/**` |
|
|
597
|
+
| `patch build` | `Makefile`, `Containerfile`, `deploy.sh`, `redeploy.sh` |
|
|
598
|
+
| `patch claude` | Claude Code slash commands shipped with the template (`.claude/commands/**`) |
|
|
609
599
|
|
|
610
|
-
|
|
600
|
+
User-customized files are never patched: for MCP this means `src/tools/`, `src/resources/`, `src/prompts/`, `src/middleware/`, `pyproject.toml`, etc. For agent/workflow it means `src/agent.py`, `agent.yaml`, `chart/values.yaml`, `src/fipsagents/**` (managed by `fips-agents vendor`), and `pyproject.toml`.
|
|
611
601
|
|
|
612
602
|
All patch subcommands (except `check`) accept `--dry-run` to preview changes without modifying files.
|
|
613
603
|
|
|
@@ -946,6 +936,22 @@ MIT License - see LICENSE file for details
|
|
|
946
936
|
|
|
947
937
|
## Changelog
|
|
948
938
|
|
|
939
|
+
### Version 0.9.1
|
|
940
|
+
|
|
941
|
+
- Chore: Realign `tests/` formatting with black 26.3.1 to match CI (v0.9.0's release pipeline failed because local black 24.x produced different output than CI's 26.x; no functional change)
|
|
942
|
+
|
|
943
|
+
### Version 0.9.0
|
|
944
|
+
|
|
945
|
+
- Feature: `fips-agents patch` now supports agent and workflow projects in addition to MCP servers (#12)
|
|
946
|
+
- Feature: New `patch chart` and `patch claude` subcommands for agent/workflow projects (#15)
|
|
947
|
+
- Feature: `.template-info` now records `template.type` and (for monorepo templates) `template.subdir` so post-scaffolding commands can route by project type (#13)
|
|
948
|
+
- Feature: New `find_fips_project_root()` walks up to `.template-info`, replacing the MCP-only fastmcp-dependency probe in patch commands (#14)
|
|
949
|
+
- Improvement: `_clone_template_for_patch()` resolves the monorepo subdir during patching, so glob/compare runs against `templates/agent-loop/` instead of the monorepo root (#16)
|
|
950
|
+
- Improvement: Running an MCP-only subcommand inside an agent project (or vice versa) now exits with a clear "available categories" error
|
|
951
|
+
- Improvement: `patch all` enumerates the project's actual category set instead of assuming MCP layout
|
|
952
|
+
- Backwards compat: Projects scaffolded before `template.type` existed default to `mcp-server`; no migration required
|
|
953
|
+
- Tests: 20 new tests in `tests/test_patch.py` covering the type-aware patch flow end-to-end against a fake-scaffolded agent project
|
|
954
|
+
|
|
949
955
|
### Version 0.8.2
|
|
950
956
|
|
|
951
957
|
- Test: New `TestGenerateMiddlewareRealTemplate` integration test renders the real v3.x middleware Jinja2 template against each `--hook-type` and the no-flag case, with templates committed under `tests/fixtures/middleware_template/` so the suite runs offline (#3)
|
|
@@ -524,7 +524,9 @@ When using `--params` with `generate tool` or `generate prompt`, provide a JSON
|
|
|
524
524
|
|
|
525
525
|
### Patch Commands
|
|
526
526
|
|
|
527
|
-
The `patch` command group updates files in existing
|
|
527
|
+
The `patch` command group updates files in existing projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
|
|
528
|
+
|
|
529
|
+
Supported project types: **MCP server**, **agent**, **workflow**. The available category subcommands depend on the project type — `patch` reads `template.type` from `.template-info` and surfaces a clear error if you run a category that doesn't apply (e.g. `patch generators` inside an agent project).
|
|
528
530
|
|
|
529
531
|
Run these commands from within your project directory.
|
|
530
532
|
|
|
@@ -534,47 +536,35 @@ Run these commands from within your project directory.
|
|
|
534
536
|
fips-agents patch check
|
|
535
537
|
```
|
|
536
538
|
|
|
537
|
-
Check for available template updates. Shows what files have changed in the template since your project was created, organized by category.
|
|
538
|
-
|
|
539
|
-
#### `patch generators`
|
|
540
|
-
|
|
541
|
-
```bash
|
|
542
|
-
fips-agents patch generators [--dry-run]
|
|
543
|
-
```
|
|
544
|
-
|
|
545
|
-
Update code generator templates (Jinja2 templates in `.fips-agents-cli/generators/`).
|
|
539
|
+
Check for available template updates. Shows what files have changed in the template since your project was created, organized by category. Works for any supported project type.
|
|
546
540
|
|
|
547
|
-
#### `patch
|
|
548
|
-
|
|
549
|
-
```bash
|
|
550
|
-
fips-agents patch core [--dry-run]
|
|
551
|
-
```
|
|
552
|
-
|
|
553
|
-
Update core infrastructure files (loaders, server bootstrap).
|
|
554
|
-
|
|
555
|
-
#### `patch docs`
|
|
541
|
+
#### `patch all`
|
|
556
542
|
|
|
557
543
|
```bash
|
|
558
|
-
fips-agents patch
|
|
544
|
+
fips-agents patch all [--dry-run] [--skip-confirmation]
|
|
559
545
|
```
|
|
560
546
|
|
|
561
|
-
Update
|
|
562
|
-
|
|
563
|
-
#### `patch build`
|
|
547
|
+
Update every category that applies to the current project type. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
|
|
564
548
|
|
|
565
|
-
|
|
566
|
-
fips-agents patch build [--dry-run]
|
|
567
|
-
```
|
|
549
|
+
#### MCP server categories
|
|
568
550
|
|
|
569
|
-
|
|
551
|
+
| Subcommand | Patches |
|
|
552
|
+
|----------------------|--------------------------------------------------------------------------|
|
|
553
|
+
| `patch generators` | Jinja2 templates in `.fips-agents-cli/generators/` |
|
|
554
|
+
| `patch core` | Core infrastructure (loaders, server bootstrap) |
|
|
555
|
+
| `patch docs` | Documentation files and examples |
|
|
556
|
+
| `patch build` | Build and deployment files (Makefile, Containerfile) |
|
|
570
557
|
|
|
571
|
-
####
|
|
558
|
+
#### Agent / workflow categories
|
|
572
559
|
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
560
|
+
| Subcommand | Patches |
|
|
561
|
+
|----------------|-------------------------------------------------------------------------------|
|
|
562
|
+
| `patch chart` | Helm chart templates (`chart/templates/**`, `chart/Chart.yaml`) |
|
|
563
|
+
| `patch docs` | `CLAUDE.md`, `AGENTS.md`, `docs/**` |
|
|
564
|
+
| `patch build` | `Makefile`, `Containerfile`, `deploy.sh`, `redeploy.sh` |
|
|
565
|
+
| `patch claude` | Claude Code slash commands shipped with the template (`.claude/commands/**`) |
|
|
576
566
|
|
|
577
|
-
|
|
567
|
+
User-customized files are never patched: for MCP this means `src/tools/`, `src/resources/`, `src/prompts/`, `src/middleware/`, `pyproject.toml`, etc. For agent/workflow it means `src/agent.py`, `agent.yaml`, `chart/values.yaml`, `src/fipsagents/**` (managed by `fips-agents vendor`), and `pyproject.toml`.
|
|
578
568
|
|
|
579
569
|
All patch subcommands (except `check`) accept `--dry-run` to preview changes without modifying files.
|
|
580
570
|
|
|
@@ -913,6 +903,22 @@ MIT License - see LICENSE file for details
|
|
|
913
903
|
|
|
914
904
|
## Changelog
|
|
915
905
|
|
|
906
|
+
### Version 0.9.1
|
|
907
|
+
|
|
908
|
+
- Chore: Realign `tests/` formatting with black 26.3.1 to match CI (v0.9.0's release pipeline failed because local black 24.x produced different output than CI's 26.x; no functional change)
|
|
909
|
+
|
|
910
|
+
### Version 0.9.0
|
|
911
|
+
|
|
912
|
+
- Feature: `fips-agents patch` now supports agent and workflow projects in addition to MCP servers (#12)
|
|
913
|
+
- Feature: New `patch chart` and `patch claude` subcommands for agent/workflow projects (#15)
|
|
914
|
+
- Feature: `.template-info` now records `template.type` and (for monorepo templates) `template.subdir` so post-scaffolding commands can route by project type (#13)
|
|
915
|
+
- Feature: New `find_fips_project_root()` walks up to `.template-info`, replacing the MCP-only fastmcp-dependency probe in patch commands (#14)
|
|
916
|
+
- Improvement: `_clone_template_for_patch()` resolves the monorepo subdir during patching, so glob/compare runs against `templates/agent-loop/` instead of the monorepo root (#16)
|
|
917
|
+
- Improvement: Running an MCP-only subcommand inside an agent project (or vice versa) now exits with a clear "available categories" error
|
|
918
|
+
- Improvement: `patch all` enumerates the project's actual category set instead of assuming MCP layout
|
|
919
|
+
- Backwards compat: Projects scaffolded before `template.type` existed default to `mcp-server`; no migration required
|
|
920
|
+
- Tests: 20 new tests in `tests/test_patch.py` covering the type-aware patch flow end-to-end against a fake-scaffolded agent project
|
|
921
|
+
|
|
916
922
|
### Version 0.8.2
|
|
917
923
|
|
|
918
924
|
- Test: New `TestGenerateMiddlewareRealTemplate` integration test renders the real v3.x middleware Jinja2 template against each `--hook-type` and the no-flag case, with templates committed under `tests/fixtures/middleware_template/` so the suite runs offline (#3)
|
|
@@ -263,6 +263,7 @@ def mcp_server(
|
|
|
263
263
|
project_name,
|
|
264
264
|
MCP_SERVER_TEMPLATE_URL,
|
|
265
265
|
template_commit,
|
|
266
|
+
template_type="mcp-server",
|
|
266
267
|
github_repo=github_repo,
|
|
267
268
|
github_url=github_url,
|
|
268
269
|
)
|
|
@@ -545,6 +546,8 @@ def agent(
|
|
|
545
546
|
project_name,
|
|
546
547
|
AGENT_TEMPLATE_URL,
|
|
547
548
|
template_commit,
|
|
549
|
+
template_type="agent",
|
|
550
|
+
template_subdir=AGENT_TEMPLATE_SUBDIR,
|
|
548
551
|
github_repo=github_repo,
|
|
549
552
|
github_url=github_url,
|
|
550
553
|
)
|
|
@@ -804,6 +807,8 @@ def workflow(
|
|
|
804
807
|
project_name,
|
|
805
808
|
AGENT_TEMPLATE_URL,
|
|
806
809
|
template_commit,
|
|
810
|
+
template_type="workflow",
|
|
811
|
+
template_subdir=WORKFLOW_TEMPLATE_SUBDIR,
|
|
807
812
|
github_repo=github_repo,
|
|
808
813
|
github_url=github_url,
|
|
809
814
|
)
|
|
@@ -1062,6 +1067,7 @@ def gateway(
|
|
|
1062
1067
|
project_name,
|
|
1063
1068
|
GATEWAY_TEMPLATE_URL,
|
|
1064
1069
|
template_commit,
|
|
1070
|
+
template_type="gateway",
|
|
1065
1071
|
github_repo=github_repo,
|
|
1066
1072
|
github_url=github_url,
|
|
1067
1073
|
)
|
|
@@ -1320,6 +1326,7 @@ def ui(
|
|
|
1320
1326
|
project_name,
|
|
1321
1327
|
UI_TEMPLATE_URL,
|
|
1322
1328
|
template_commit,
|
|
1329
|
+
template_type="ui",
|
|
1323
1330
|
github_repo=github_repo,
|
|
1324
1331
|
github_url=github_url,
|
|
1325
1332
|
)
|
|
@@ -1577,6 +1584,7 @@ def sandbox(
|
|
|
1577
1584
|
project_name,
|
|
1578
1585
|
SANDBOX_TEMPLATE_URL,
|
|
1579
1586
|
template_commit,
|
|
1587
|
+
template_type="sandbox",
|
|
1580
1588
|
github_repo=github_repo,
|
|
1581
1589
|
github_url=github_url,
|
|
1582
1590
|
)
|
|
@@ -10,10 +10,10 @@ from rich.table import Table
|
|
|
10
10
|
from fips_agents_cli.tools.patching import (
|
|
11
11
|
check_for_updates,
|
|
12
12
|
get_available_categories,
|
|
13
|
-
|
|
13
|
+
get_project_type,
|
|
14
14
|
patch_category,
|
|
15
15
|
)
|
|
16
|
-
from fips_agents_cli.tools.validation import
|
|
16
|
+
from fips_agents_cli.tools.validation import find_fips_project_root
|
|
17
17
|
|
|
18
18
|
console = Console()
|
|
19
19
|
|
|
@@ -33,23 +33,14 @@ def check():
|
|
|
33
33
|
"""
|
|
34
34
|
console.print("\n[bold cyan]Checking for Template Updates[/bold cyan]\n")
|
|
35
35
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
if not project_root:
|
|
36
|
+
found = find_fips_project_root()
|
|
37
|
+
if not found:
|
|
39
38
|
console.print(
|
|
40
39
|
"[red]✗[/red] Not in a project directory\n"
|
|
41
40
|
"[yellow]Hint:[/yellow] Run this command from within a project created by fips-agents"
|
|
42
41
|
)
|
|
43
42
|
sys.exit(1)
|
|
44
|
-
|
|
45
|
-
# Get template info
|
|
46
|
-
template_info = get_template_info(project_root)
|
|
47
|
-
if not template_info:
|
|
48
|
-
console.print(
|
|
49
|
-
"[red]✗[/red] No template metadata found\n"
|
|
50
|
-
"[yellow]Hint:[/yellow] This project may not have been created by fips-agents-cli"
|
|
51
|
-
)
|
|
52
|
-
sys.exit(1)
|
|
43
|
+
project_root, template_info = found
|
|
53
44
|
|
|
54
45
|
console.print("[green]✓[/green] Project created from template")
|
|
55
46
|
console.print(f" Template: {template_info['template']['url']}")
|
|
@@ -134,6 +125,37 @@ def build(dry_run: bool):
|
|
|
134
125
|
_patch_category("build", dry_run)
|
|
135
126
|
|
|
136
127
|
|
|
128
|
+
@patch.command("chart")
|
|
129
|
+
@click.option(
|
|
130
|
+
"--dry-run",
|
|
131
|
+
is_flag=True,
|
|
132
|
+
help="Show what would be updated without making changes",
|
|
133
|
+
)
|
|
134
|
+
def chart(dry_run: bool):
|
|
135
|
+
"""
|
|
136
|
+
Update Helm chart templates (agent / workflow projects only).
|
|
137
|
+
|
|
138
|
+
Patches files under chart/templates/ and chart/Chart.yaml.
|
|
139
|
+
chart/values.yaml is never patched (user-customized).
|
|
140
|
+
"""
|
|
141
|
+
_patch_category("chart", dry_run)
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
@patch.command("claude")
|
|
145
|
+
@click.option(
|
|
146
|
+
"--dry-run",
|
|
147
|
+
is_flag=True,
|
|
148
|
+
help="Show what would be updated without making changes",
|
|
149
|
+
)
|
|
150
|
+
def claude(dry_run: bool):
|
|
151
|
+
"""
|
|
152
|
+
Update Claude Code slash commands (agent / workflow projects only).
|
|
153
|
+
|
|
154
|
+
Patches files under .claude/commands/ that ship with the template.
|
|
155
|
+
"""
|
|
156
|
+
_patch_category("claude", dry_run)
|
|
157
|
+
|
|
158
|
+
|
|
137
159
|
@patch.command("all")
|
|
138
160
|
@click.option(
|
|
139
161
|
"--dry-run",
|
|
@@ -153,13 +175,23 @@ def all_categories(dry_run: bool, skip_confirmation: bool):
|
|
|
153
175
|
"""
|
|
154
176
|
console.print("\n[bold cyan]Patching All Categories[/bold cyan]\n")
|
|
155
177
|
|
|
178
|
+
found = find_fips_project_root()
|
|
179
|
+
if not found:
|
|
180
|
+
console.print(
|
|
181
|
+
"[red]✗[/red] Not in a project directory\n"
|
|
182
|
+
"[yellow]Hint:[/yellow] Run this command from within a project created by fips-agents"
|
|
183
|
+
)
|
|
184
|
+
sys.exit(1)
|
|
185
|
+
_, template_info = found
|
|
186
|
+
project_type = get_project_type(template_info)
|
|
187
|
+
|
|
156
188
|
if not skip_confirmation:
|
|
157
189
|
confirm = click.confirm("This will update multiple files. Continue?", default=True)
|
|
158
190
|
if not confirm:
|
|
159
191
|
console.print("[yellow]Cancelled[/yellow]")
|
|
160
192
|
sys.exit(0)
|
|
161
193
|
|
|
162
|
-
categories = get_available_categories()
|
|
194
|
+
categories = get_available_categories(project_type)
|
|
163
195
|
for category in categories:
|
|
164
196
|
console.print(f"\n[bold]Processing category: {category}[/bold]")
|
|
165
197
|
_patch_category(category, dry_run, skip_confirmation=skip_confirmation)
|
|
@@ -174,23 +206,14 @@ def _patch_category(category: str, dry_run: bool, skip_confirmation: bool = Fals
|
|
|
174
206
|
dry_run: If True, only show what would be changed
|
|
175
207
|
skip_confirmation: If True, don't ask for confirmation
|
|
176
208
|
"""
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
if not project_root:
|
|
209
|
+
found = find_fips_project_root()
|
|
210
|
+
if not found:
|
|
180
211
|
console.print(
|
|
181
212
|
"[red]✗[/red] Not in a project directory\n"
|
|
182
213
|
"[yellow]Hint:[/yellow] Run this command from within a project created by fips-agents"
|
|
183
214
|
)
|
|
184
215
|
sys.exit(1)
|
|
185
|
-
|
|
186
|
-
# Get template info
|
|
187
|
-
template_info = get_template_info(project_root)
|
|
188
|
-
if not template_info:
|
|
189
|
-
console.print(
|
|
190
|
-
"[red]✗[/red] No template metadata found\n"
|
|
191
|
-
"[yellow]Hint:[/yellow] This project may not have been created by fips-agents-cli"
|
|
192
|
-
)
|
|
193
|
-
sys.exit(1)
|
|
216
|
+
project_root, template_info = found
|
|
194
217
|
|
|
195
218
|
# Perform patch
|
|
196
219
|
success, message = patch_category(
|