Project Rules
Updated
RightNow Agent, the terminal coding agent, is paused. Its guides stay online as reference.
Project rules give RightNow Agent the conventions and instructions for a directory tree.
Write project rules
Save your project conventions in AGENTS.md at the repository root.
Then inspect the loaded rules.
Recognized files
Within each directory, RightNow checks these names in order and loads each readable matching file that is not excluded by applicable ignore rules:
- 1Agents.md
- 2Claude.md
- 3CLAUDE.md
- 4CLAUDE.local.md
- 5AGENT.md
- 6AGENTS.md
- On case-insensitive filesystems, names that resolve to the same file are deduplicated. Top-level Claude-compatible names remain recognized even when machine-wide Claude imports are disabled.
- Only these names count as top-level instruction files; inside a rules directory, readable
*.mdfiles at its top level load unless ignored. - Each file loads in full, with no size cap, so keep rules short.
Load order and scope
- Home rules load first:
<RIGHTNOW_HOME>/rules/*.md, then~/.claude/and~/.cursor/sources when their compatibility settings allow. - Inside a repository, rules load from the repository root down to the current working directory.
- If the working directory is not in a repository, only its local project rules are scanned.
- Rules in deeper directories appear later, so they win when instructions conflict. Files in a rules directory load alphabetically.
In this example, the working directory is repo/src/components. Home rules load first. Project rules then load from the repository root down to that working directory. The three shown AGENTS.md files accumulate in that order. Rules closer to the working directory load later and take precedence when their instructions conflict, as described in the project rules guide. The example shows only these three project rule files. Other enabled rule files and compatible home rule locations can also contribute. Outside a Git repository, project discovery checks the working directory itself, alongside the home rules. A configured workspace user directory can also be inserted into the project discovery chain.
Starting in src/components loads all three files. The components rule has the final word on conflicts because it is deepest. Instruction files in directories the agent reads later are noted and read when they apply.
Build from source
The flags and inspection commands below describe the source build.
Session-only rules
Use --rules, also available as --append-system-prompt, to add temporary instructions without editing a file.
RightNow wraps this text in <human_rules> and appends it when a session is created. A system prompt override (--system-prompt-override, alias --system-prompt) replaces the base prompt and retains the supplied <human_rules> block. Without an effective system prompt override, changing --rules while resuming leaves the existing rules unchanged. With an effective override, the resumed session uses that override and the currently supplied rules.
The project extension directory
Prefer the .rightnow/ paths. RightNow reads them first and still honors the legacy paths below.
| Path | Purpose and fallback |
|---|---|
| .rightnow/config.toml | Project MCP servers, plugins, and permission rules. Reads the legacy config path when the corresponding preferred file is absent. |
| .rightnow/rules/*.md | Both the native and legacy rule directories are scanned, subject to ignore rules and file readability. |
| .rightnow/skills/ | Project skills. The legacy skill directory and .agents/skills/ are scanned too. |
| .rightnow/plugins/ | Project plugins. Reads the legacy plugin directory as a fallback. |
| .rightnow/hooks/ | Project hooks. At the repository root, reads the legacy hook directory when the preferred directory is absent. |
| .rightnow/agents/ | Project-scoped agent definitions. |
| .rightnow/lsp.json | Project-scoped LSP server configuration. |
| .rightnow/sandbox.toml | Project sandbox profiles. |
Compatible rule discovery also covers .claude/rules/*.md, .cursor/rules/*.md, and the project files .claude/CLAUDE.md and .claude/CLAUDE.local.md when their compatibility settings are enabled.
The configuration template sets skills, rules, and agents to false under [compat.claude] and [compat.cursor]. This disables vendor skill and rule discovery and vendor-prefixed instruction paths. Native RightNow rules and recognized top-level project files such as CLAUDE.md still load. To change this, set the [compat] keys listed under Agents and extensions in the configuration reference.
Inspect what loaded
It lists the discovered project instructions with their paths and approximate token counts. Add --json for machine-readable output.
Next task
Review the compatibility settings for the rule sources you need.