-
NEVER use
git commit- usegs commit create -m "message"instead -
NEVER use
git push- usegs stack submitinstead -
Before implementing multi-step features, present the stack structure for approval
-
Use conventional commits:
type(scope): description -
After submitting, provide the PR link from the output
./scripts/install_workflow.sh
| Command | Shorthand | Purpose |
|---------|-----------|---------|
| gs branch create | gs bc | Create new branch stacked on current |
| gs commit create | gs cc | Stage and commit changes |
| gs stack submit | gs ss | Submit entire stack as PRs |
| gs repo sync | gs rs | Pull latest, delete merged branches |
| gs stack restack | gs sr | Rebase all branches in stack |
| gs log long --all | gs ll -a | Show dependency tree |
| gs branch checkout | gs bco | Switch branches |
| gs up / gs down | - | Navigate stack |
| gs w <branch> | gs w <branch> | Add worktree |
| gs w clean <branch> | gs w clean <branch> | Clean up worktree |
-
Write code for first PR
-
gs commit create -m "feat(scope): description"(auto-stages with-a) -
gs branch create feat-nameto start next stacked branch -
Repeat steps 1-3 for each stacked PR
-
gs stack submitto push entire stack and create PRs
gs repo sync # Pull trunk, delete merged branches
gs stack restack # Rebase stack after trunk changes
gs ll -a # View full stack tree