Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .rulesync/specification-augmentcode-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "AugmentCode ignore files specification for controlling AI file access"
globs: ["**/*.gitignore", "**/.augmentignore"]
globs: []
---

# AugmentCode Ignore Files Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-augmentcode-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "AugmentCode MCP (Model Context Protocol) configuration specification"
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# AugmentCode MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-augmentcode-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "AugmentCode rules specification for configuration file generation"
globs: ["**/*.ts", "**/*.js", "**/*.md"]
globs: []
---

# AugmentCode Rules Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-claudecode-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Claude Code settings.json permission.deny specification for security configuration
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# Claude Code settings.json permission.deny Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-claudecode-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Claude Code MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# Claude Code MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-cline-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["cline"]
description: "Specification document for Cline VSCode Extension .clineignore file"
globs: ["**/.clineignore"]
globs: []
---

# Cline VSCode Extension Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-cline-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Cline MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# Cline MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-codexcli-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "OpenAI Codex CLI file exclusion and ignore patterns specification"
globs: ["**/.codexignore", "**/.gitignore", "**/*.json", "**/*.toml", "**/*.yaml"]
globs: []
---

# OpenAI Codex CLI Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-codexcli-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "OpenAI Codex CLI MCP (Model Context Protocol) server configuration specification"
globs: ["**/*.json", "**/*.toml", "**/*.yaml", "**/*.yml", "**/*.js", "**/*.ts"]
globs: []
---

# OpenAI Codex CLI MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-codexcli-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "OpenAI Codex CLI instructions and memory file specification"
globs: ["**/*.md", "**/*.toml", "**/*.yaml", "**/*.yml", "**/*.json"]
globs: []
---

# OpenAI Codex CLI Rules/Memory Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-copilot-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["copilot"]
description: "GitHub Copilot Content exclusion feature specification"
globs: ["**/*.yml", "**/*.yaml"]
globs: []
---

# GitHub Copilot Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-copilot-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: GitHub Copilot MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# GitHub Copilot MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-cursor-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["cursor"]
description: "Cursor IDE .cursorignore and .cursorindexingignore file specification"
globs: ["**/.cursorignore", "**/.cursorindexingignore"]
globs: []
---

# Cursor IDE Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-cursor-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Cursor MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# Cursor MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-gemincli-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "Gemini CLI Coding Assistant .aiexclude file specification"
globs: ["**/.aiexclude", "**/.gitignore"]
globs: []
---

# Gemini CLI Coding Assistant Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-gemincli-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Gemini CLI MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# Gemini CLI MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-gemincli-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: Gemini CLI Memory (GEMINI.md) specification for configuration file generation
globs: ["**/*.ts", "**/*.js", "**/*.md"]
globs: []
---

# Gemini CLI Memory (GEMINI.md) Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-junie-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "JetBrains Junie .aiignore file specification for controlling file access and privacy"
globs: ["**/*"]
globs: []
---

# JetBrains Junie Ignore Files Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-junie-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "JetBrains Junie Model Context Protocol (MCP) server configuration specification"
globs: ["**/*"]
globs: []
---

# JetBrains Junie MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-junie-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "JetBrains Junie AI coding assistant guidelines and rules configuration specification"
globs: ["**/*"]
globs: []
---

# JetBrains Junie Guidelines and Rules Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-kiro-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "Kiro IDE ignore files specification and best practices"
globs: ["src/**/*.ts"]
globs: []
---

# Kiro Ignore Files Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-kiro-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "Kiro IDE MCP (Model Context Protocol) configuration and AWS integration"
globs: ["**/*"]
globs: []
---

# Kiro MCP (Model Context Protocol) Configuration Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-kiro-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: "Kiro IDE spec-driven development and steering documents configuration"
globs: ["src/**/*.ts"]
globs: []
---

# Kiro Rules and Steering Documentation Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-roo-ignore.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["roo"]
description: "Roocode AI Coding Assistant .rooignore file specification"
globs: ["**/.rooignore"]
globs: []
---

# Roocode AI Coding Assistant Ignore File Specification
Expand Down
2 changes: 1 addition & 1 deletion .rulesync/specification-roo-mcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
root: false
targets: ["*"]
description: RooCode MCP (Model Context Protocol) configuration specification
globs: ["**/*.json", "**/*.ts", "**/*.js"]
globs: []
---

# RooCode MCP (Model Context Protocol) Configuration Specification
Expand Down
1 change: 1 addition & 0 deletions cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
"Kiro",
"Kiro's",
"kirodeignore",
"kiroignore",
"lightningcss",
"lilconfig",
"lintstagedrc",
Expand Down
16 changes: 11 additions & 5 deletions src/core/generator.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,18 @@ describe("generateConfigurations", () => {
it("should generate claudecode configuration correctly", async () => {
const outputs = await generateConfigurations(mockRules, mockConfig, ["claudecode"]);

expect(outputs.length).toBeGreaterThan(0);
expect(outputs.length).toBe(3); // 1 detail file + 1 root file + 1 settings file

// First output should be detail file
expect(outputs[0]!.tool).toBe("claudecode");
expect(outputs[0]!.filepath).toBe("CLAUDE.md");
expect(outputs[0]!.content).toContain("This is a test rule");
expect(outputs[0]!.content).toContain("@.claude/memories/claudecode-only.md");
expect(outputs[0]!.content).not.toContain("This is a copilot only rule");
expect(outputs[0]!.filepath).toBe(".claude/memories/claudecode-only.md");

// Second output should be root file
expect(outputs[1]!.tool).toBe("claudecode");
expect(outputs[1]!.filepath).toBe("CLAUDE.md");
expect(outputs[1]!.content).toContain("This is a test rule");
expect(outputs[1]!.content).toContain("@.claude/memories/claudecode-only.md");
expect(outputs[1]!.content).not.toContain("This is a copilot only rule");
});

it("should handle empty rules gracefully", async () => {
Expand Down
10 changes: 4 additions & 6 deletions src/generators/ignore/codexcli.test.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { describe, expect, it } from "vitest";
import type { Config, ParsedRule } from "../../types/index.js";
import { createMockConfigByTool } from "../../test-utils/mock-config.js";
import type { ParsedRule } from "../../types/index.js";
import { generateCodexCliIgnoreFiles } from "./codexcli.js";

describe("generateCodexCliIgnoreFiles", () => {
const mockConfig: Config = {
aiRulesDir: ".rulesync",
const mockConfig = createMockConfigByTool("codexcli", {
outputPaths: {
augmentcode: "./.augment/rules",
"augmentcode-legacy": "./.augment-guidelines",
Expand All @@ -18,9 +18,7 @@ describe("generateCodexCliIgnoreFiles", () => {
kiro: "./.kiro/steering",
junie: "./.junie/guidelines.md",
},
watchEnabled: false,
defaultTargets: ["codexcli"],
};
});

it("should generate .codexignore file with basic content", async () => {
const rules: ParsedRule[] = [];
Expand Down
10 changes: 4 additions & 6 deletions src/generators/ignore/junie.test.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { describe, expect, it } from "vitest";
import type { Config, ParsedRule } from "../../types/index.js";
import { createMockConfigByTool } from "../../test-utils/mock-config.js";
import type { ParsedRule } from "../../types/index.js";
import { generateJunieIgnoreFiles } from "./junie.js";

describe("generateJunieIgnoreFiles", () => {
const mockConfig: Config = {
aiRulesDir: ".rulesync",
const mockConfig = createMockConfigByTool("junie", {
outputPaths: {
augmentcode: "./.augment/rules",
"augmentcode-legacy": "./.augment-guidelines",
Expand All @@ -18,9 +18,7 @@ describe("generateJunieIgnoreFiles", () => {
kiro: "./.kiro/steering",
junie: "./.junie/guidelines.md",
},
watchEnabled: false,
defaultTargets: ["junie"],
};
});

it("should generate .aiignore file with basic content", async () => {
const rules: ParsedRule[] = [];
Expand Down
Loading