Skip to content

Commit c6fdf93

Browse files
authored
Merge pull request dyoshikawa#1309 from dyoshikawa/enhance-gitignore
2 parents ddcb336 + b056c19 commit c6fdf93

10 files changed

Lines changed: 758 additions & 294 deletions

File tree

.gitignore

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -217,35 +217,35 @@ mcp-schema.json
217217
docs/.vitepress/dist
218218
docs/.vitepress/cache
219219

220-
**/.junie/skills/
221-
**/.junie/agents/
222-
223220
# Generated by Rulesync
224221
.rulesync/skills/.curated/
222+
.rulesync/rules/*.local.md
223+
rulesync.local.jsonc
224+
!.rulesync/.aiignore
225225
**/AGENTS.md
226226
**/.agents/
227-
**/.augmentignore
228227
**/.augment/rules/
229228
**/.augment-guidelines
229+
**/.augmentignore
230230
**/CLAUDE.md
231231
**/CLAUDE.local.md
232232
**/.claude/CLAUDE.md
233233
**/.claude/CLAUDE.local.md
234-
**/.claude/memories/
235234
**/.claude/rules/
236235
**/.claude/commands/
237236
**/.claude/agents/
238237
**/.claude/skills/
239-
**/.claude/settings.local.json
240238
**/.mcp.json
239+
**/.claude/memories/
240+
**/.claude/settings.local.json
241241
**/.clinerules/
242242
**/.clinerules/workflows/
243243
**/.clineignore
244244
**/.cline/mcp.json
245245
**/.codexignore
246-
**/.codex/memories/
247246
**/.codex/skills/
248247
**/.codex/agents/
248+
**/.codex/memories/
249249
**/.codex/config.toml
250250
**/.cursor/
251251
**/.cursorignore
@@ -256,21 +256,25 @@ docs/.vitepress/cache
256256
**/.factory/mcp.json
257257
**/.factory/settings.json
258258
**/GEMINI.md
259-
**/.gemini/memories/
260259
**/.gemini/commands/
261260
**/.gemini/subagents/
262261
**/.gemini/skills/
263262
**/.geminiignore
263+
**/.gemini/memories/
264264
**/.goosehints
265265
**/.goose/
266266
**/.gooseignore
267+
**/.github/copilot-instructions.md
268+
**/.github/instructions/
267269
**/.github/prompts/
268270
**/.github/agents/
269271
**/.github/skills/
270272
**/.github/hooks/
271273
**/.vscode/mcp.json
272274
**/.junie/guidelines.md
273275
**/.junie/mcp.json
276+
**/.junie/skills/
277+
**/.junie/agents/
274278
**/.kilocode/rules/
275279
**/.kilocode/skills/
276280
**/.kilocode/workflows/
@@ -282,11 +286,11 @@ docs/.vitepress/cache
282286
**/.kiro/agents/
283287
**/.kiro/settings/mcp.json
284288
**/.aiignore
285-
**/.opencode/memories/
286289
**/.opencode/command/
287290
**/.opencode/agent/
288291
**/.opencode/skill/
289292
**/.opencode/plugins/
293+
**/.opencode/memories/
290294
**/QWEN.md
291295
**/.qwen/memories/
292296
**/replit.md
@@ -297,6 +301,3 @@ docs/.vitepress/cache
297301
**/.roo/subagents/
298302
**/.warp/
299303
**/WARP.md
300-
.rulesync/rules/*.local.md
301-
rulesync.local.jsonc
302-
!.rulesync/.aiignore

docs/getting-started/quick-start.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ rulesync install && rulesync generate
8080
# Add generated files to .gitignore
8181
rulesync gitignore
8282

83+
# Add only specific tool entries to .gitignore
84+
rulesync gitignore --targets claudecode,copilot
85+
8386
# Update rulesync to the latest version (single-binary installs)
8487
rulesync update
8588

docs/reference/cli-commands.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,12 @@ rulesync install && rulesync generate
4848
# Add generated files to .gitignore
4949
rulesync gitignore
5050

51+
# Add only specific tool entries to .gitignore
52+
rulesync gitignore --targets claudecode,copilot
53+
54+
# Add only specific feature entries to .gitignore
55+
rulesync gitignore --targets copilot --features rules,commands
56+
5157
# Update rulesync to the latest version (single-binary installs)
5258
rulesync update
5359

@@ -58,6 +64,39 @@ rulesync update --check
5864
rulesync update --force
5965
```
6066

67+
## Gitignore Command
68+
69+
The `gitignore` command adds generated AI tool configuration files to `.gitignore`. By default, it includes entries for all supported tools and features. You can optionally filter the output to include only specific tools or features.
70+
71+
### Options
72+
73+
| Option | Description | Default |
74+
| --------------------------- | ---------------------------------------------------------------------------------------------------- | --------- |
75+
| `--targets, -t <tools>` | Comma-separated list of tools to include (e.g., `claudecode,copilot` or `*` for all) | `*` (all) |
76+
| `--features, -f <features>` | Comma-separated list of features to include (rules, commands, subagents, skills, ignore, mcp, hooks) | `*` (all) |
77+
78+
### Examples
79+
80+
```bash
81+
# Add all entries (default)
82+
rulesync gitignore
83+
84+
# Add entries for Claude Code only
85+
rulesync gitignore --targets claudecode
86+
87+
# Add entries for multiple tools
88+
rulesync gitignore --targets claudecode,copilot,cursor
89+
90+
# Add only rules and commands entries for Copilot
91+
rulesync gitignore --targets copilot --features rules,commands
92+
```
93+
94+
### Behavior
95+
96+
- **Common entries** (e.g., `.rulesync/skills/.curated/`, `rulesync.local.jsonc`) are always included regardless of filters.
97+
- **General entries** (e.g., memories, settings) are always included when their target is selected.
98+
- When re-running, all previously generated rulesync entries are removed before writing the new filtered set.
99+
61100
## Fetch Command
62101

63102
The `fetch` command allows you to fetch configuration files directly from a Git repository (GitHub/GitLab).

skills/rulesync/cli-commands.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,12 @@ rulesync install && rulesync generate
4848
# Add generated files to .gitignore
4949
rulesync gitignore
5050

51+
# Add only specific tool entries to .gitignore
52+
rulesync gitignore --targets claudecode,copilot
53+
54+
# Add only specific feature entries to .gitignore
55+
rulesync gitignore --targets copilot --features rules,commands
56+
5157
# Update rulesync to the latest version (single-binary installs)
5258
rulesync update
5359

@@ -58,6 +64,39 @@ rulesync update --check
5864
rulesync update --force
5965
```
6066

67+
## Gitignore Command
68+
69+
The `gitignore` command adds generated AI tool configuration files to `.gitignore`. By default, it includes entries for all supported tools and features. You can optionally filter the output to include only specific tools or features.
70+
71+
### Options
72+
73+
| Option | Description | Default |
74+
| --------------------------- | ---------------------------------------------------------------------------------------------------- | --------- |
75+
| `--targets, -t <tools>` | Comma-separated list of tools to include (e.g., `claudecode,copilot` or `*` for all) | `*` (all) |
76+
| `--features, -f <features>` | Comma-separated list of features to include (rules, commands, subagents, skills, ignore, mcp, hooks) | `*` (all) |
77+
78+
### Examples
79+
80+
```bash
81+
# Add all entries (default)
82+
rulesync gitignore
83+
84+
# Add entries for Claude Code only
85+
rulesync gitignore --targets claudecode
86+
87+
# Add entries for multiple tools
88+
rulesync gitignore --targets claudecode,copilot,cursor
89+
90+
# Add only rules and commands entries for Copilot
91+
rulesync gitignore --targets copilot --features rules,commands
92+
```
93+
94+
### Behavior
95+
96+
- **Common entries** (e.g., `.rulesync/skills/.curated/`, `rulesync.local.jsonc`) are always included regardless of filters.
97+
- **General entries** (e.g., memories, settings) are always included when their target is selected.
98+
- When re-running, all previously generated rulesync entries are removed before writing the new filtered set.
99+
61100
## Fetch Command
62101

63102
The `fetch` command allows you to fetch configuration files directly from a Git repository (GitHub/GitLab).

skills/rulesync/quick-start.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ rulesync install && rulesync generate
8080
# Add generated files to .gitignore
8181
rulesync gitignore
8282

83+
# Add only specific tool entries to .gitignore
84+
rulesync gitignore --targets claudecode,copilot
85+
8386
# Update rulesync to the latest version (single-binary installs)
8487
rulesync update
8588

0 commit comments

Comments
 (0)