Pathrule is the shared memory, rules, and skills layer for AI coding agents.
Use the CLI to connect a local repository to Pathrule, sync the workspace context agents need, and install Pathrule into tools such as Claude Code, Cursor, Codex, and Windsurf.
Install the CLI:
npm i -g @pathrule/cliRun setup from the repository you want to connect:
cd your-project
pathrule setuppathrule setup guides you through sign-in when needed, finds or creates the
right workspace, attaches the current folder, syncs local companion files, and
offers to install Pathrule for your AI tools.
- Path-scoped context, delivered just in time instead of pasted into every chat.
- Shared memory, rules, and skills that survive between AI sessions.
- One workspace layer for Claude Code, Cursor, Codex, Windsurf, and other MCP-compatible tools.
- Local setup for companion files, MCP config, SSH sessions, and headless terminals.
- A privacy-first model: Pathrule does not read, scan, or upload your source code.
pathrule setup
pathrule sync
pathrule start
pathrule statusFor diagnostics:
pathrule doctorFor scripted setup:
pathrule setup --json
pathrule setup --workspace <workspace-id-or-name> --target all --yesPathrule CLI requires Node.js >=20.11.1 on every supported platform.
After install, the binary lives at whatever path your npm global prefix
puts it — verify with command -v pathrule (macOS/Linux) or
where pathrule (Windows).
npm i -g @pathrule/cli
pathrule login
pathrule setup
pathrule doctorUpgrade:
npm i -g @pathrule/cli@latestnpm i -g @pathrule/cli
pathrule login
pathrule setup
pathrule doctorOptional: the bridge daemon can run under systemd --user if your
distro ships user services. pathrule daemon start works without
systemd; the daemon stays foreground until you stop it.
npm i -g @pathrule/cli
pathrule login
pathrule setup
pathrule doctorNotes:
- Windows autostart for the bridge daemon is not yet wired up. Start
it manually with
pathrule daemon start.pathrule daemon status --jsonreportssupported: false, method: "task-scheduler"so scripts can distinguish a planned no-op from a real failure. - The CLI writes a
pathrule-hook.cmdshim next topathrule-hook.jsinside%USERPROFILE%\.pathrule\bin\. AI clients that spawn hooks without a shell (Codex on Windows) execute the.cmddirectly. - If you use a corporate proxy or custom CA, set
HTTPS_PROXY,HTTP_PROXY,NO_PROXY, orNODE_EXTRA_CA_CERTSin the env before runningpathrule install <client>— the CLI propagates those values into the managed MCP entry so AI-client-spawned MCP can still reach Supabase.
The Homebrew formula is generated by every release but the tap is not
yet publishing publicly. Until the pathrule/homebrew-tap repository
goes live, prefer npm i -g @pathrule/cli@latest. Once the tap is up,
brew upgrade pathrule will be advertised through versions.json.
Pathrule keeps per-user state in ~/.pathrule on every supported OS by
default. Override with PATHRULE_HOME if you need a custom location:
PATHRULE_HOME=/srv/pathrule pathrule syncpathrule install <client> propagates the active PATHRULE_HOME into
the managed MCP entry so AI-client-spawned MCP reads the same
credentials.
Most users do not need to run pathrule login manually. pathrule setup
starts the hosted Pathrule authorization flow when the CLI is not signed in.
You can still sign in directly:
pathrule loginThe login flow shows a one-time code and opens Pathrule Web in your browser.
Pathrule is designed for team workspaces without taking custody of your repository:
- Your source code stays on your machine.
- Cloud access uses user sessions, not embedded service keys.
- Workspace permissions are enforced server-side and by database row-level security.
- The local bridge binds to loopback and is intended for local browser and CLI workflows only.
For more details, visit pathrule.io.