---
id: 260415-nfi
slug: remove-env-setup
date: 2026-04-15
status: complete
---

# Summary: Remove env-setup skill + subcommand

## What changed

- **Deleted** `plugin/spt/skills/env-setup/` (in-repo, marketplace, and active install via thorough deploy)
- **Deleted** `src/owl/env_setup.rs`
- **Removed** `mod env_setup;` and the `Commands::EnvSetup` dispatch arm from `src/owl/mod.rs`
- **Removed** the `EnvSetup` variant from `src/cli.rs` (including its doc comment)
- **Updated** `src/owl/doctor.rs`: env-vars-missing advice now says "restart Claude Code to re-run the SessionStart hook" (was "run env-setup or restart Claude Code")
- **Purged** the `If commands fail with "command not found", run /spt:env-setup.` line from 17 SKILL.md files, replaced with "restart the Claude Code session so the SessionStart hook re-runs"
- **Updated** `docs/DEPLOY.md` line 142: env-vars-missing runbook now points to session restart + `$OWL doctor`; a one-line note explains why env-setup was removed (settings.json pins broke upgrades)
- **Bumped** plugin version `1.7.0` → `1.7.1`
- **Thorough deploy executed**: rebuild, sync to marketplace, wipe cache (only 1.7.1/ now), refresh active install. All five owl.exe hashes match `e95ac158…`. env-setup skill confirmed gone from marketplace + active install. settings.json env keys clean.

## Why

`env-setup` was a v1.0-owl relic (skills-only, no plugin). The plugin's
SessionStart hook now handles env injection via `CLAUDE_ENV_FILE` automatically.
`env-setup`'s preferred path was redundant with the hook; its fallback path wrote
binary paths into `~/.claude/settings.json`, which pinned the version and
overrode the hook's dynamic injection on upgrades — exactly the failure mode
that hid Phase 18.1 behind v1.5.7 for multiple sessions. Correct recovery is
session restart (hook re-fires); `$OWL doctor` diagnoses genuine failures.

## Verification

- `cargo build --release` clean (7.62s, 3 pre-existing warnings)
- `cargo test --release` all green
- Post-deploy final audit: build + in-repo + marketplace + cache + active install all on sha `e95ac158…`
- Zero `env-setup` / `EnvSetup` / `env_setup` refs in `src/` or `plugin/`; only the deliberate historical mention remains in `docs/DEPLOY.md:142`
