Installation
Requirements, the install command, choosing AI tools and updating.
Requirements
- Node.js 20.9 or newer.
- A
package.jsonwithnext(Next.js) or@tanstack/react-start(TanStack Start). Otherwise pass--framework. - Run the command in the project root, next to
package.json.
Install
$ pnpm dlx @virastack/ai initThe CLI prints what it detected, then every file it writes. With no flags it installs rules for both Claude Code and Cursor:
ViraStack AI v2.0.0
Framework: nextjs · Agents: claude, cursor · i18n: no · Package manager: pnpm
+ .claude/rules/virastack/core.md · created
+ .claude/rules/virastack/architecture.md · created
...
+ .cursor/rules/virastack/nextjs.mdc · created
+ AGENTS.md · created
+ CLAUDE.md · created
+ .virastack/ai.json · created
27 created · 0 updated · 0 removed · 0 skipped
ViraStack AI rules are ready.Commit the new files, including .virastack/ai.json. Teammates and future updates rely on it.
Choose your AI tools
Use --agent to install rules only for the tools you use:
$ pnpm dlx @virastack/ai init --agent claude--agent claude:.claude/rules/virastack/and the@AGENTS.mdline inCLAUDE.md.--agent cursor:.cursor/rules/virastack/.--agent claude,cursor: both. This is the default.--agent none: plain Markdown rules in.agents/rules/virastack/, read through theAGENTS.mdmap.
The choice is saved in .virastack/ai.json and reused by the next init. Run init with a different --agent to switch; the other tool’s rule files are removed.
With ViraStack Start
ViraStack Start asks “Which AI coding tools do you use?” and runs ViraStack AI with your answer. In an existing Start project, add or refresh the rules with add ai:
$ pnpm dlx virastack@latest add ai --agent claudeUpdate
$ pnpm dlx @virastack/ai@2 initRun init again. Rules you did not change are updated, rules a new version drops are removed, and rules you changed are kept unless you confirm. See customization for changed rules and --force.
