fix: Worktree scripts use $(pwd) for project root
Scripts now correctly determine project root from current working
directory instead of calculating relative to script location.
This fixes the issue when scripts are called via ${CLAUDE_PLUGIN_ROOT}.
Also adds CLAUDE.md and CHANGELOG.md for development guidance.
Bumps version to 1.0.3.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -7,9 +7,8 @@ set -e
|
||||
|
||||
FEATURE_NAME="$1"
|
||||
|
||||
# Get project root (parent of .auto-build)
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
PROJECT_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
||||
# Get project root from current working directory (where Claude Code is running)
|
||||
PROJECT_ROOT="$(pwd)"
|
||||
PROJECT_NAME=$(basename "$PROJECT_ROOT")
|
||||
WORKTREES_DIR="$(dirname "$PROJECT_ROOT")/ab-worktrees"
|
||||
|
||||
@@ -104,5 +103,5 @@ else
|
||||
|
||||
echo ""
|
||||
echo "To cleanup a specific worktree:"
|
||||
echo " bash .auto-build/scripts/worktree-cleanup.sh <feature-name>"
|
||||
echo " /ab:worktree cleanup <feature-name>"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user