Skip to content

raniejade/rac

Repository files navigation

rac

RAC keeps .rac/ as the source of truth for agent, skill, MCP, rule, and vendor-wide config definitions, then generates Claude, Codex, and OpenCode config surfaces from that source.

Use it to:

  • Install project-local config from a repository's .rac/.
  • Install user/global config from ~/.rac/.
  • Share reusable config packs across repositories.
  • Generate vendor-native outputs while keeping ownership tracked in RAC install manifests.

Requirements

  • Node.js >=20
  • npm

Project Quick Start

Project scope reads <cwd>/.rac/ and writes project-local vendor outputs.

# Scaffold .rac/ in the current project
npx @raniejade/rac init

# Validate source definitions
npx @raniejade/rac doctor

# Preview generated project outputs
npx @raniejade/rac install --dry-run

# Apply generated project outputs
npx @raniejade/rac install

User Quick Start

User scope reads ~/.rac/ and writes global/home config surfaces.

# Scaffold ~/.rac/
npx @raniejade/rac init --scope user

# Validate ~/.rac/
npx @raniejade/rac doctor --scope user

# Preview global outputs
npx @raniejade/rac install --scope user --dry-run

# Apply global outputs
npx @raniejade/rac install --scope user

For dotfiles, manage the .rac tree directly in your dotfiles repo and deploy or symlink it to ~/.rac. RAC_HOME is for relocation/testing because it changes the user-scope source home and the Claude/Codex target home; OpenCode user outputs still follow XDG_CONFIG_HOME.

Shared Packs

Project .rac/config.toml can reference shared packs:

npx @raniejade/rac pack add platform-rules github:owner/repo --ref main
npx @raniejade/rac pack list
npx @raniejade/rac install --refresh-packs --dry-run

Pack commands edit the current project's .rac/config.toml.

rac install creates .rac/rac-lock.json (committed alongside config.toml) that pins each pack to its resolved commit SHA. Subsequent installs on any machine check out the locked SHA rather than re-resolving the floating ref, so two developers and a CI job installing the same project always produce identical outputs. Use --refresh-packs to re-resolve refs and rewrite the lockfile. Use --frozen-lockfile (exit code 2 if the lockfile would change) in CI to gate on unreviewed lockfile drift. Pack overrides skip the lockfile entirely. See Lockfile for full details.

For iterating on a pack locally, see Local Pack Overrides — a developer-only redirect via .rac/config.local.toml.

Docs

  • Install Scopes: project scope, user scope, dotfiles workflow, and output paths.
  • Configuration: .rac/ layout, definition schemas, commands, merge behavior, shared packs, target outputs, and troubleshooting.
  • Architecture: internal pipeline and ownership boundaries.

Verification

docker build -f docker/smoke.Dockerfile --target smoke-test -t rac-smoke-test .

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors