@acmeacmeio/setup-sh 0.2.6
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/README.md +212 -0
- package/package.json +39 -0
- package/src/cli.mjs +614 -0
- package/templates/.claude/agents/code-simplifier.md +52 -0
- package/templates/.claude/commands/auto.md +85 -0
- package/templates/.claude/commands/clean-copy.md +93 -0
- package/templates/.claude/commands/fix-issue.md +34 -0
- package/templates/.claude/commands/review.md +46 -0
- package/templates/.claude/router/classify.js +241 -0
- package/templates/.claude/router/registry.json +49 -0
- package/templates/.claude/settings.json +113 -0
- package/templates/.claude/skills/api-design/SKILL.md +77 -0
- package/templates/.claude/skills/security-review/SKILL.md +65 -0
- package/templates/.codex/config.toml +31 -0
- package/templates/.codex/skills/api-design/SKILL.md +77 -0
- package/templates/.codex/skills/security-review/SKILL.md +65 -0
- package/templates/.cursor/commands/auto.md +55 -0
- package/templates/.cursor/commands/clean-copy.md +80 -0
- package/templates/.cursor/commands/code-simplifier.md +28 -0
- package/templates/.cursor/commands/fix-issue.md +28 -0
- package/templates/.cursor/commands/review.md +41 -0
- package/templates/.cursor/hooks.json +11 -0
- package/templates/.cursor/rules/api-design.mdc +80 -0
- package/templates/.cursor/rules/git-workflow.mdc +73 -0
- package/templates/.cursor/rules/security.mdc +69 -0
- package/templates/.cursor/rules/tdd.mdc +35 -0
- package/templates/.cursor/rules/typescript.mdc +82 -0
- package/templates/.cursorignore.template +20 -0
- package/templates/.gitignore.template +10 -0
- package/templates/.mcp.json +16 -0
- package/templates/AGENTS.md +118 -0
- package/templates/CLAUDE.md +138 -0
package/README.md
ADDED
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
# setup-sh
|
|
2
|
+
|
|
3
|
+
Bootstrap a multi-agent workspace with team standards, hooks, and skills for Claude Code, OpenAI Codex, and Cursor IDE.
|
|
4
|
+
|
|
5
|
+
## Supported Agents
|
|
6
|
+
|
|
7
|
+
| Agent | Config | Instructions | Skills/Rules |
|
|
8
|
+
|-------|--------|--------------|--------------|
|
|
9
|
+
| **Claude Code** (Anthropic) | `.claude/settings.json` | `CLAUDE.md` | `.claude/skills/` |
|
|
10
|
+
| **Codex** (OpenAI) | `.codex/config.toml` | `AGENTS.md` | `.codex/skills/` |
|
|
11
|
+
| **Cursor** (Cursor IDE) | `.cursor/hooks.json` | `CLAUDE.md`* | `.cursor/rules/` |
|
|
12
|
+
|
|
13
|
+
\* Cursor natively reads `CLAUDE.md` and `AGENTS.md`
|
|
14
|
+
|
|
15
|
+
## Usage
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
# Interactive mode (prompts for agent selection)
|
|
19
|
+
npx @acmeacmeio/setup-sh
|
|
20
|
+
|
|
21
|
+
# Specify agent via flag
|
|
22
|
+
npx @acmeacmeio/setup-sh . --agent=claude # Claude Code only
|
|
23
|
+
npx @acmeacmeio/setup-sh . --agent=codex # Codex only
|
|
24
|
+
npx @acmeacmeio/setup-sh . --agent=cursor # Cursor IDE only
|
|
25
|
+
npx @acmeacmeio/setup-sh . --agent=all # All agents
|
|
26
|
+
|
|
27
|
+
# Create new project directory
|
|
28
|
+
npx @acmeacmeio/setup-sh my-project --agent=all
|
|
29
|
+
|
|
30
|
+
# Non-interactive mode
|
|
31
|
+
npx @acmeacmeio/setup-sh my-project --agent=claude --yes
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## What It Does
|
|
35
|
+
|
|
36
|
+
1. **Installs Required Tools** (if missing)
|
|
37
|
+
- GitHub CLI (`gh`)
|
|
38
|
+
- Node.js
|
|
39
|
+
- pnpm
|
|
40
|
+
- Python 3.11+ and uv
|
|
41
|
+
|
|
42
|
+
2. **Creates Workspace Structure**
|
|
43
|
+
|
|
44
|
+
**Claude Code:**
|
|
45
|
+
```
|
|
46
|
+
.claude/
|
|
47
|
+
├── settings.json # Permissions, hooks
|
|
48
|
+
├── commands/ # Slash commands (/tdd, /review, etc.)
|
|
49
|
+
├── skills/ # Domain knowledge
|
|
50
|
+
└── router/ # Intent classification system
|
|
51
|
+
CLAUDE.md # Team standards
|
|
52
|
+
.mcp.json # MCP server configuration
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
**Codex:**
|
|
56
|
+
```
|
|
57
|
+
.codex/
|
|
58
|
+
├── config.toml # Model, sandbox, MCP servers
|
|
59
|
+
└── skills/ # Domain knowledge (same format as Claude)
|
|
60
|
+
AGENTS.md # Team standards
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
**Cursor:**
|
|
64
|
+
```
|
|
65
|
+
.cursor/
|
|
66
|
+
├── rules/ # MDC rules with YAML frontmatter
|
|
67
|
+
│ ├── tdd.mdc # Always apply - TDD methodology
|
|
68
|
+
│ ├── typescript.mdc # Auto-attach on *.ts, *.tsx
|
|
69
|
+
│ ├── api-design.mdc # Agent requested - REST patterns
|
|
70
|
+
│ ├── security.mdc # Agent requested - Security checklist
|
|
71
|
+
│ └── git-workflow.mdc # Agent requested - Git conventions
|
|
72
|
+
├── commands/ # Plain markdown commands
|
|
73
|
+
└── hooks.json # Post-edit formatting hooks
|
|
74
|
+
.cursorignore # Files to exclude from Cursor context
|
|
75
|
+
CLAUDE.md # Team standards (Cursor reads this natively)
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
3. **Installs Skills**
|
|
79
|
+
- Claude Code: External skills via `npx add-skill`
|
|
80
|
+
- Codex: Bundled skills in `.codex/skills/`
|
|
81
|
+
- Cursor: Bundled rules in `.cursor/rules/`
|
|
82
|
+
|
|
83
|
+
## Feature Comparison
|
|
84
|
+
|
|
85
|
+
| Feature | Claude Code | Codex | Cursor |
|
|
86
|
+
|---------|-------------|-------|--------|
|
|
87
|
+
| Instructions file | `CLAUDE.md` | `AGENTS.md` | `CLAUDE.md`* |
|
|
88
|
+
| Config format | JSON | TOML | JSON |
|
|
89
|
+
| Rules/Skills format | `SKILL.md` | `SKILL.md` | `.mdc` (MDC) |
|
|
90
|
+
| Hooks | Pre/Post tool use | Notify only | afterFileEdit |
|
|
91
|
+
| MCP servers | `.mcp.json` | `config.toml` | N/A |
|
|
92
|
+
| Permissions | Allowlist/denylist | Sandbox modes | N/A |
|
|
93
|
+
| Rule application | `/skill-name` | `$skill-name` | globs/alwaysApply |
|
|
94
|
+
|
|
95
|
+
\* Cursor also reads `AGENTS.md`
|
|
96
|
+
|
|
97
|
+
## Cursor MDC Rules
|
|
98
|
+
|
|
99
|
+
Cursor uses MDC (Markdown with YAML frontmatter) format for rules:
|
|
100
|
+
|
|
101
|
+
```markdown
|
|
102
|
+
---
|
|
103
|
+
description: TypeScript strict mode patterns
|
|
104
|
+
globs:
|
|
105
|
+
- "**/*.ts"
|
|
106
|
+
- "**/*.tsx"
|
|
107
|
+
alwaysApply: false
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
# TypeScript Patterns
|
|
111
|
+
|
|
112
|
+
Content here...
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### Rule Types
|
|
116
|
+
|
|
117
|
+
| Type | Configuration | Behavior |
|
|
118
|
+
|------|---------------|----------|
|
|
119
|
+
| **Always Apply** | `alwaysApply: true`, `globs: []` | Active for all files |
|
|
120
|
+
| **Auto Attached** | `alwaysApply: false`, `globs: ["*.ts"]` | Active when matching files open |
|
|
121
|
+
| **Agent Requested** | `alwaysApply: false`, `globs: []` | Agent decides when to use |
|
|
122
|
+
|
|
123
|
+
## What You Get
|
|
124
|
+
|
|
125
|
+
### Commands (Claude Code)
|
|
126
|
+
|
|
127
|
+
- `/fix-issue <number>` - Fix a GitHub issue with TDD workflow
|
|
128
|
+
- `/review` - Run code review checklist
|
|
129
|
+
- `/clean-copy` - Restructure commits into clean history
|
|
130
|
+
- `/auto` - Auto-detect best workflow
|
|
131
|
+
|
|
132
|
+
### Rules (Cursor)
|
|
133
|
+
|
|
134
|
+
- `tdd.mdc` - TDD methodology (always apply)
|
|
135
|
+
- `typescript.mdc` - TypeScript patterns (auto-attach on .ts/.tsx)
|
|
136
|
+
- `api-design.mdc` - REST + Zod patterns (agent requested)
|
|
137
|
+
- `security.mdc` - Security checklist (agent requested)
|
|
138
|
+
- `git-workflow.mdc` - Git conventions (agent requested)
|
|
139
|
+
|
|
140
|
+
### Skills (Both Claude Code & Codex)
|
|
141
|
+
|
|
142
|
+
- `$api-design` - REST + Zod patterns
|
|
143
|
+
- `$security-review` - Security audit checklist
|
|
144
|
+
|
|
145
|
+
### Hooks
|
|
146
|
+
|
|
147
|
+
**Claude Code:**
|
|
148
|
+
- Auto-format: Prettier + ESLint on every edit
|
|
149
|
+
- Security: Blocks `.env` file modifications
|
|
150
|
+
- Intent routing: Suggests commands based on prompts
|
|
151
|
+
|
|
152
|
+
**Cursor:**
|
|
153
|
+
- Auto-format: Prettier + ESLint after file edit
|
|
154
|
+
|
|
155
|
+
## Setup for Users
|
|
156
|
+
|
|
157
|
+
Configure npm to use GitHub Packages for the `@acmeacmeio` scope:
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
# Add to ~/.npmrc
|
|
161
|
+
@acmeacmeio:registry=https://npm.pkg.github.com
|
|
162
|
+
//npm.pkg.github.com/:_authToken=YOUR_GITHUB_TOKEN
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
Then run:
|
|
166
|
+
|
|
167
|
+
```bash
|
|
168
|
+
npx @acmeacmeio/setup-sh my-project
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
## Local Development
|
|
172
|
+
|
|
173
|
+
```bash
|
|
174
|
+
# Test locally without publishing
|
|
175
|
+
cd packages/setup-sh
|
|
176
|
+
node src/cli.mjs /path/to/test-project
|
|
177
|
+
|
|
178
|
+
# Or link globally
|
|
179
|
+
npm link
|
|
180
|
+
setup-sh /path/to/test-project
|
|
181
|
+
|
|
182
|
+
# Test specific agent
|
|
183
|
+
node src/cli.mjs /tmp/test --agent=cursor
|
|
184
|
+
node src/cli.mjs /tmp/test --agent=codex
|
|
185
|
+
node src/cli.mjs /tmp/test --agent=all
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
## Customization
|
|
189
|
+
|
|
190
|
+
After running the command, customize:
|
|
191
|
+
|
|
192
|
+
### Claude Code
|
|
193
|
+
1. **`CLAUDE.md`** - Edit team standards
|
|
194
|
+
2. **`.claude/settings.json`** - Adjust permissions and hooks
|
|
195
|
+
3. **`.claude/commands/`** - Add custom slash commands
|
|
196
|
+
4. **`.claude/skills/`** - Add domain-specific knowledge
|
|
197
|
+
|
|
198
|
+
### Codex
|
|
199
|
+
1. **`AGENTS.md`** - Edit team standards
|
|
200
|
+
2. **`.codex/config.toml`** - Adjust model, sandbox, MCP servers
|
|
201
|
+
3. **`.codex/skills/`** - Add domain-specific knowledge
|
|
202
|
+
|
|
203
|
+
### Cursor
|
|
204
|
+
1. **`CLAUDE.md`** - Edit team standards (Cursor reads this natively)
|
|
205
|
+
2. **`.cursor/rules/`** - Add custom MDC rules
|
|
206
|
+
3. **`.cursor/commands/`** - Add custom commands
|
|
207
|
+
4. **`.cursor/hooks.json`** - Adjust post-edit hooks
|
|
208
|
+
5. **`.cursorignore`** - Exclude files from Cursor context
|
|
209
|
+
|
|
210
|
+
## License
|
|
211
|
+
|
|
212
|
+
MIT
|
package/package.json
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@acmeacmeio/setup-sh",
|
|
3
|
+
"version": "0.2.6",
|
|
4
|
+
"description": "Bootstrap a multi-agent workspace (Claude Code, Codex, Cursor) with team standards, hooks, and skills",
|
|
5
|
+
"author": "ACMEACMEIO",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"bin": {
|
|
8
|
+
"setup-sh": "./src/cli.mjs"
|
|
9
|
+
},
|
|
10
|
+
"type": "module",
|
|
11
|
+
"files": [
|
|
12
|
+
"src",
|
|
13
|
+
"templates"
|
|
14
|
+
],
|
|
15
|
+
"keywords": [
|
|
16
|
+
"claude",
|
|
17
|
+
"claude-code",
|
|
18
|
+
"codex",
|
|
19
|
+
"openai",
|
|
20
|
+
"cursor",
|
|
21
|
+
"cursor-ide",
|
|
22
|
+
"ai",
|
|
23
|
+
"developer-tools",
|
|
24
|
+
"workspace",
|
|
25
|
+
"scaffold",
|
|
26
|
+
"multi-agent"
|
|
27
|
+
],
|
|
28
|
+
"engines": {
|
|
29
|
+
"node": ">=18.0.0"
|
|
30
|
+
},
|
|
31
|
+
"publishConfig": {
|
|
32
|
+
"registry": "https://registry.npmjs.org",
|
|
33
|
+
"access": "public"
|
|
34
|
+
},
|
|
35
|
+
"repository": {
|
|
36
|
+
"type": "git",
|
|
37
|
+
"url": "https://github.com/acmeacmeio/setup-sh"
|
|
38
|
+
}
|
|
39
|
+
}
|