Setup and Config Commands
Level 4 · Setup and extensions
The commands that set a project up: /init, /import, /config and /permissions. Then three more that write settings files for you when you ask.
Course contentsLesson 9 of 17
Level 1 · Get started
Level 2 · Inside a conversation
Level 3 · Parallel work and review
Level 4 · Setup and extensions
Level 5 · Scripts and servers
After this lesson you can
- Start a project's CLAUDE.md with /init
- Set one setting from the prompt with /config
- Draft allow rules from your past sessions
12 mincovers 11 glossary entries
Worth reading first: Diff and Code Review
How to set a project up without editing files by hand
/init is the first command to run in a new project. It reads the code and writes a first CLAUDE.md. That file holds the build steps, test steps and habits it finds. If one is there already, /init suggests changes instead. Set CLAUDE_CODE_NEW_INIT to 1 for a longer setup with skills and hooks too.
/import brings your setup over from another coding agent. That can be Codex, Gemini CLI or Cursor. It copies rule files, linked tools, commands, helpers and skills. Add --dry-run to see the list first, with nothing written. It does not work when Claude runs on Bedrock, Vertex or Foundry.
/config opens the settings panel. You can also set one value straight from the prompt, such as /config theme=dark, and that form works in -p runs too. /config --help lists the keys it takes, and /settings is another name for it. A few settings need a yes in the panel, so the one-line form cannot turn them on.
/permissions opens the rules that say what Claude may do without asking. You see the allow, ask and deny rules for each scope, and can add or remove them. Each permission rule names a tool and, if you like, a pattern. The dialog also lists extra work folders and the last calls auto mode turned down.
Auto mode is the permission mode where a checker model says yes or no to each call for you. At first it trusts only your work folder and this project's code host. /auto-mode-setup reads your project and recent sessions. It lists the hosts and buckets you use and drafts more places to trust. You read the draft, then it saves to your user settings.
claude auto-mode shows, from the shell, the rules that checker follows. claude auto-mode defaults prints the built-in rules as JSON. Add --label to narrow them by name. claude auto-mode config prints the rules with your settings added. claude auto-mode reset asks first, then takes your changes out of your user settings.
Two more commands write settings files for you. /fewer-permission-prompts reads your past sessions. It looks for safe commands that only read, which you keep saying yes to. Then it adds them as an allow list to the project's settings file. /update-config takes any change in plain words, such as allow npm test, and edits the file that fits.
/init
/import cursor --dry-run
/config theme=dark
/update-config allow npm test without asking
# in the shell
claude auto-mode defaults --label 'Git Destructive'Worked example
Jack stops clicking yes
Jack says yes to git status, git diff and npm test about 30 times a day. He runs /fewer-permission-prompts.
It finds 6 read-only commands in his recent sessions and shows the allow list. He accepts it, and the next day he is asked 4 times instead of 30.
The words for this lesson11
Check yourself
Which command reads your past sessions and adds an allow list to the project's settings?
Finished this lesson?
Marking it complete also marks its 11 glossary entries learned, which updates your roadmap and your saved page. 0 are already marked.