Kanri profiles let you switch editor and shell settings without rewriting your configuration. The active profile is selected by options.current_profile in config.toml.
Profiles affect commands that launch external programs, especially:
kanri open <project>kanri open <project> --shellkanri config editkanri blueprints new <name>when Kanri opens the new blueprint in your editorkanri blueprints edit <name>when Kanri opens an existing blueprint in your editor
Profiles live under the [profiles] table in the configuration file:
[profiles.default]
editor = "code"
editor_args = ["."]
editor_fork_mode = true
shell = "bash"Each profile has these fields:
editor- Program used for editor sessions.editor_args- Extra arguments passed to the editor. Code-family editors usually use["."]so the project directory opens as a workspace.editor_fork_mode- Iftrue, Kanri starts the editor and returns immediately instead of waiting for it to exit.shell- Program used for shell sessions.
Unknown profile fields are rejected when the configuration is loaded.
Note
Older Kanri versions used shell_args. Current Kanri no longer supports that field and can migrate it out of existing configuration files.
Kanri creates a default profile on first run. It detects a default editor from VISUAL or EDITOR, and a default shell from SHELL or COMSPEC on Windows.
For recognized editors — code, code-insiders, codium, code-oss, cursor, windsurf, and zed — Kanri enables fork mode and adds . to editor_args. On Windows, it also appends .cmd where needed.
# Create a profile interactively.
kanri profiles new
# List profiles. The current profile is marked.
kanri profiles list
# Show profile details.
kanri profiles get default
# Set active profile.
kanri profiles set default
# Remove a profile with confirmation.
kanri profiles remove old-profile
# Remove without prompting.
kanri profiles remove old-profile --yesKanri prevents removing the current active profile. Switch to another profile first with kanri profiles set <name>.
# Uses the current profile's editor, editor_args, and editor_fork_mode.
kanri open my-project
# Uses the current profile's shell.
kanri open my-project --shellShell sessions receive KANRI_SESSION=1 in their environment.