Build out all 27 modules + capstone (#1)
Co-authored-by: claude <claude@jpaul.io> Co-committed-by: claude <claude@jpaul.io>
This commit was merged in pull request #1.
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Module 7 lab — create two linked worktrees off the tasks-app repo, each on its own branch.
|
||||
# Run this from INSIDE your tasks-app repo (the one you git-init'd in Module 2):
|
||||
#
|
||||
# bash modules/07-worktrees-running-agents-in-parallel/lab/setup-worktrees.sh
|
||||
#
|
||||
# It places the new worktree folders next to the repo, so you end up with:
|
||||
#
|
||||
# <parent>/tasks-app (your existing repo, on its current branch)
|
||||
# <parent>/tasks-app-clear (new worktree on branch feature/clear)
|
||||
# <parent>/tasks-app-count (new worktree on branch feature/count)
|
||||
#
|
||||
set -euo pipefail
|
||||
|
||||
# The directory that contains the repo, so the new worktrees become siblings of it.
|
||||
ROOT="$(git rev-parse --show-toplevel)"
|
||||
PARENT="$(cd "$ROOT/.." && pwd)"
|
||||
|
||||
git worktree add "$PARENT/tasks-app-clear" -b feature/clear
|
||||
git worktree add "$PARENT/tasks-app-count" -b feature/count
|
||||
|
||||
echo
|
||||
echo "Worktrees created. One repo, three checked-out branches:"
|
||||
git worktree list
|
||||
Reference in New Issue
Block a user