@ctout-uk/agentsmith 0.0.0-stage → 0.1.0

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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,128 @@
1
- # Temporary Holding Version
1
+ # agentsmith
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ A cross-environment agent asset manager. Install, sync, and update agent skills, instructions, and agents from the [awesome-copilot](https://github.com/github/awesome-copilot) catalogue into VS Code, Kiro, and Antigravity — with subscription tracking, hash-based change detection, dry-run, and local-edit protection.
4
+
5
+ > **Successor to [vscode-copilot-sync](https://github.com/CTOUT/vscode-copilot-sync)** — same lifecycle safety, now cross-environment and runtime-agnostic.
6
+
7
+ ## Quick Start
8
+
9
+ ```bash
10
+ npx @ctout-uk/agentsmith sync
11
+ npx @ctout-uk/agentsmith install
12
+ ```
13
+
14
+ No install required. Requires Node 24+.
15
+
16
+ ## What it does
17
+
18
+ - **Syncs** the awesome-copilot catalogue into a local cache (`~/.agentsmith/`)
19
+ - **Installs** assets into your environment's correct locations with frontmatter translated for each target
20
+ - **Tracks** every installation in `~/.agentsmith/subscriptions.json` with SHA-256 hashes
21
+ - **Detects** local edits (`[~]`) and upstream updates (`[↑]`) before touching anything
22
+ - **Removes** only what it installed — user-created files are never touched
23
+
24
+ ## Supported environments
25
+
26
+ | Environment | Repo scope | User scope |
27
+ | --- | --- | --- |
28
+ | **VS Code** (Copilot harness) | `.github/agents/`, `.github/instructions/`, `.github/skills/` | `~/.copilot/agents/`, `~/.copilot/instructions/`, `~/.copilot/skills/` |
29
+ | **Kiro** | `.kiro/agents/`, `.kiro/steering/`, `.kiro/skills/` | `~/.kiro/agents/`, `~/.kiro/steering/`, `~/.kiro/skills/` |
30
+ | **Antigravity** | `.agents/plugins/<name>/` | `~/.gemini/config/plugins/<name>/` |
31
+
32
+ ## Commands
33
+
34
+ ```bash
35
+ agentsmith sync # Pull latest from awesome-copilot into ~/.agentsmith/
36
+ agentsmith sync --dry-run # Preview sync without writing
37
+
38
+ agentsmith install # Interactive picker for the detected environment
39
+ agentsmith install se-security-reviewer # Install a specific asset
40
+ agentsmith install --target kiro # Target a specific environment
41
+ agentsmith install --scope user # Install at user level (available everywhere)
42
+ agentsmith install --recommended # Install all recommended assets non-interactively
43
+ agentsmith install --type instruction # Filter picker by asset type
44
+ agentsmith install --search "security" # Filter picker by search term
45
+ agentsmith install --dry-run # Preview without writing
46
+
47
+ agentsmith update # Apply upstream updates to all subscriptions
48
+ agentsmith update --target vscode # Limit to a specific environment
49
+ agentsmith update --dry-run # Preview updates
50
+ agentsmith update --force # Overwrite locally modified files
51
+
52
+ agentsmith remove # Interactive picker of installed assets to remove
53
+ agentsmith remove se-security-reviewer # Remove a specific asset
54
+ agentsmith remove --dry-run # Preview removals
55
+
56
+ agentsmith list # Show all installed assets and their status
57
+ agentsmith list --target kiro # Filter by environment
58
+ agentsmith list --scope user # Filter by scope
59
+ ```
60
+
61
+ ## Status badges
62
+
63
+ | Badge | Meaning |
64
+ | --- | --- |
65
+ | `★` | Recommended for this environment |
66
+ | `[*]` | Already installed |
67
+ | `[↑]` | Update available from upstream |
68
+ | `[~]` | Locally modified since install |
69
+ | `[!]` | Requires additional setup (MCP server, API key, etc.) |
70
+
71
+ ## Portability
72
+
73
+ Assets are translated for each target environment transparently. The adapter reports what changed:
74
+
75
+ ```
76
+ installed 'security-and-owasp' -> kiro:repo [adapted: applyTo -> inclusion: fileMatch, fileMatchPattern: **/*.ts]
77
+ ```
78
+
79
+ Three outcomes are possible:
80
+
81
+ - **Native** — asset installed as-is, no changes
82
+ - **Adapted** — frontmatter translated for the target; changes reported
83
+ - **Unsupported** — asset cannot be safely installed; reason explained
84
+
85
+ ### Frontmatter translation reference
86
+
87
+ | VS Code (`applyTo`) | Kiro (`inclusion`) | Antigravity (`trigger`) |
88
+ | --- | --- | --- |
89
+ | `applyTo: "**/*.ts"` | `inclusion: fileMatch` + `fileMatchPattern: "**/*.ts"` | `trigger: glob` + `globs: "**/*.ts"` |
90
+ | `applyTo: "**"` | `inclusion: always` | `trigger: always_on` |
91
+ | *(none)* | `inclusion: always` | `trigger: always_on` |
92
+
93
+ ## Cache and subscriptions
94
+
95
+ ```
96
+ ~/.agentsmith/
97
+ ├── sources/
98
+ │ └── awesome-copilot/ # Local git checkout (sparse)
99
+ ├── catalogue.json # Metadata index for the picker
100
+ ├── manifest.json # Sync state (hashes, timestamps)
101
+ └── subscriptions.json # Installation records per target and scope
102
+ ```
103
+
104
+ > **Migration notice:** If you have an existing `~/.awesome-copilot/` directory from [vscode-copilot-sync](https://github.com/CTOUT/vscode-copilot-sync), agentsmith uses a separate `~/.agentsmith/` cache. Run `agentsmith sync` to populate it fresh.
105
+
106
+ ## Security
107
+
108
+ - Path traversal protection via `assertPathWithin` on every file write and removal operation
109
+ - Only files recorded in `subscriptions.json` are removed — user-created files are never touched
110
+ - Locally modified files are flagged `[~]` and skipped without `--force`
111
+ - `--dry-run` is available on all write commands
112
+
113
+ See [SECURITY.md](SECURITY.md) for vulnerability reporting.
114
+
115
+ ## Prerequisites
116
+
117
+ - **Node 24+** — [nodejs.org](https://nodejs.org)
118
+ - **git** — for the initial awesome-copilot clone
119
+
120
+ ## Related
121
+
122
+ - [awesome-copilot](https://github.com/github/awesome-copilot) — the community catalogue agentsmith syncs from
123
+ - [vscode-copilot-sync](https://github.com/CTOUT/vscode-copilot-sync) — the archived PowerShell predecessor
124
+ - [Agent Plugins specification](https://agent-plugins.org/specification) — portable plugin packaging standard
125
+
126
+ ## License
127
+
128
+ MIT — see [LICENSE](LICENSE)
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env node
2
+ import('../dist/cli.cjs')