--- name: setup description: Check the tools on this machine and the repository before a saga run. --- # Setup `/saga:setup` checks the tools on this machine and the repository. It does not install a tool, and it does not run an optional step, unless the operator names that id. In Claude Code, the operator can open the setup pane directly with `/setup-view`: no agent turn is needed, and the pane runs the survey, the ticked installs, and the optional steps itself. The repository questions below stay here — the pane points the operator back at this skill for those. ## Survey **In Claude Code, when the tool `mcp__saga__setup` is listed and the operator has not disabled panes, call it with `{"repo": ""}` instead of running the survey below, and parse the JSON string it returns to read its `status`.** Submitted names the installed and failed ids — never reinstall them; run the survey below, print its table, and continue with the Questions section exactly as if the tool were absent. Dismissed, not-placed, unavailable, nothing-to-review, timed-out or error means the pane settled nothing: run the survey below, print its table, and ask which tools to install exactly as if the tool were absent. Run the survey with the live sandbox probe and print the table: ```bash python3 plugins/saga/scripts/saga_setup.py survey --repo --probe-sandbox live ``` The survey also records, in the machine record `~/.saga/machine.json`, the digest of the rule pack cache at `~/.saga/semgrep-rules/p--security-audit` when that cache exists, so the security scanner can run on any repository. Run the survey again after refreshing the cache. It never downloads or ships the pack, and it writes nothing about the pack into the repository. Read the table. It names each selected tool, its lens, its status, and its pinned version. It names credential names only as present or absent. It names whether reproduction is available. ## Questions Ask the numbered questions the survey prints. Do not invent an answer. Do not print an environment value. Record the operator's answers: ```bash python3 plugins/saga/scripts/saga_setup.py write --repo --answers ``` ## Install and steps Run an install only for tool ids the operator names: ```bash python3 plugins/saga/scripts/saga_setup.py install --tools --repo ``` Run an optional step only when the operator names it: ```bash python3 plugins/saga/scripts/saga_setup.py step --name ``` A row with no install command is not installed by this skill. Say the install sentence and stop. Offer the `outcome-schedule` step only on macOS where `launchctl` exists. Step vectors resolve against the saga plugin root, from a source checkout or an installed package alike. After setting up a repository, register it with `python3 plugins/saga/scripts/outcome_job.py register --repo-root `.