Skip to content

n45-ai init

Set up N45 in the current folder — as a Project or a Workspace.

Synopsis

npx n45-ai@latest init [--kind project|workspace] [--tool claude,cursor,codex]

Prerequisites

  • Node.js 22 or newer
  • Git installed on your machine
  • An active N45.AI license and a prior npx n45-ai@latest login

Description

init first asks what you're setting up:

  • Project — a single repository (an app, a microservice, a monorepo).
  • Workspace — a group of repositories, polyrepo (see the Workspace section).

If the folder already contains git subfolders (candidate members), init detects a Workspace automatically and skips the question — use --kind project to override.

It then asks which IDE assistants you use (Claude Code, Cursor, or Codex) and sets things up:

  • Project — creates the .n45/ directory, the IDE configuration (.claude/, .cursor/, or .codex/) and the slash commands (/n45, /n45-feat, /n45-fix, /n45-status, /n45-run, /n45-next).
  • Workspace — creates the coordination .n45/ (the workspace name is the folder name, no prompt), then lists the git folders it found and offers to add them as members, all pre-selected — just confirm. Each member is prepared automatically. See Set up a Workspace for the full flow.

init does not download the binary — that happens on first use (login, status, or a slash command), or explicitly via install.

Must be run from the root of your project (or the workspace folder). Requires a prior npx n45-ai@latest login — which itself requires an active N45.AI license.

Non-interactive

Pass flags to skip the prompts (useful in scripts/CI):

  • --kind project|workspace — skip the Project/Workspace question.
  • --tool <a,b> — the IDE tools (repeatable or comma-separated); skip the tools prompt.
npx n45-ai@latest init --kind workspace --tool claude,cursor

Already set up with a different version?

If the project already has N45 skills and a .n45/ folder from a different version, init stops and asks you to run upgrade first. This guarantees the project's .n45/ is migrated before the skills are replaced — running new skills against an old .n45/ schema would corrupt it. Re-running init on the same version is safe (e.g. to add another IDE).

What it modifies

File / folder Action
.n45/ Created (a project or a workspace, per your choice)
.claude/ Created (skills + settings)
.cursor/ Created (skills + cli.json + .cursorignore)
.codex/ Created (skills + permissions)

In a workspace, each member you add also gets its own .n45/ and skills, set up automatically. Your existing settings are preserved when N45 updates a shared file.

Examples

# a single-repo project (interactive)
cd /path/to/your/project
npx n45-ai@latest init

# a workspace (auto-detected if the folder already has git repos inside)
cd /path/to/your/workspace
npx n45-ai@latest init

See also