Repository navigation
fix(review): stop source env from running /usr/bin/env - #10
Merged
Merged
Conversation
## Short Summary (TL;DR) The review skill's env file is now `review.env`, sourced by its absolute path. An agent that ran `source env` in the review directory ran `/usr/bin/env` instead, so the next ddev command used the user's real global config. ## The Issue Bash's `source` looks a name without a slash up on `PATH` before the current directory. The review skill wrote its env file as `env`, so `source env` found `/usr/bin/env` and failed. Commands after it ran without `DDEV_XDG_CONFIG_HOME`. In one review, this started a test project in the user's own global config and recreated their `ddev-router`. Agents hit it in several reviews. ## How This PR Solves The Issue - The file is now `review.env`, which isn't on `PATH`. - The example shows sourcing it by its absolute path in each later command. ## Manual Testing Instructions ```bash cd "$(mktemp -d "$HOME/tmp/env-test.XXXXXX")" echo 'export X=ok' > env && echo 'export X=ok' > review.env source env; echo "X=$X" # Expect "source: /usr/bin/env: cannot execute binary file" and an empty X source review.env; echo "X=$X" # Expect X=ok ``` ## Automated Testing Overview No tests cover skill text. Claude Code ran `claude plugin validate .`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Short Summary (TL;DR)
The review skill's env file is now
review.env, sourced by its absolute path. An agent that ransource envin the review directory ran/usr/bin/envinstead, so the next ddev command used the user's real global config.The Issue
Bash's
sourcelooks a name without a slash up onPATHbefore the current directory. The review skill wrote its env file asenv, sosource envfound/usr/bin/envand failed. Commands after it ran withoutDDEV_XDG_CONFIG_HOME. In one review, this started a test project in the user's own global config and recreated theirddev-router. Agents hit it in several reviews.How This PR Solves The Issue
review.env, which isn't onPATH.Manual Testing Instructions
Automated Testing Overview
No tests cover skill text. Claude Code ran
claude plugin validate ..🤖 Generated with Claude Code