.cursor/commands/goham.md
End-to-end workflow for working on tasks from a connected Hamster brief. All tasks from the brief are worked on in a single branch, with one PR created at the end.
# Check current context and authentication status
tm context
If not connected or authentication fails:
tm context <brief url>tm auth refresh# View all tasks from the brief
tm list
Review the task list to understand what needs to be done. Note the total number of tasks.
# Ensure you're on dev branch and pull latest
git checkout dev
git pull origin dev
# Create a single branch for the entire brief (e.g., hamster-brief-YYYY-MM-DD or brief-specific name)
git checkout -b hamster-brief
# Verify branch creation
git branch
Note: This branch will be used for ALL tasks in the brief. Do not create separate branches per task.
Work through all tasks sequentially in the same branch:
# Get detailed information about the task
tm show 1
# If task has subtasks, examine them all
tm show 1,1.1,1.2,1.3 # Adjust IDs as needed
# Document task understanding and initial findings
tm update-task -i 1 --append --prompt="Starting task implementation.
Initial context:
- Task requirements: [summarize key requirements]
- Dependencies identified: [list any dependencies]
- Files that may need modification: [list relevant files]
- Approach planned: [brief implementation approach]"
# Mark task and first subtask (if exists) as in-progress
tm set-status -i 1,1.1 -s in-progress
For each subtask (1.1, 1.2, 1.3, etc.):
tm show 1.1 # Replace with current subtask ID
# Document findings during implementation
tm update-task -i 1 --append --prompt="Subtask 1.1 - Context gathered:
- Code exploration findings: [what you discovered]
- Implementation approach: [how you plan to implement]
- Key decisions made: [important choices]
- Challenges encountered: [any blockers or issues]"
# Run linting
pnpm lint
# Run type checking
pnpm typecheck
# If either fails, fix issues and re-run until both pass
# Generate code review (wait for plain text results)
coderabbit --prompt-only
# Review the output and address any critical issues if needed
# Document what was completed
tm update-task -i 1 --append --prompt="Subtask 1.1 - Implementation complete:
- Files modified: [list files changed]
- Key changes: [summary of implementation]
- CodeRabbit feedback addressed: [if any issues were fixed]
- Ready for commit"
# Stage changes
git add .
# Commit with detailed message following git_workflow.mdc format
git commit -m "feat(task-1): Complete subtask 1.1 - [Subtask Title]
- Implementation details
- Key changes made
- Files modified: [list files]
- CodeRabbit review completed
Subtask 1.1: [Brief description of what was accomplished]
Relates to Task 1: [Main task title]"
tm set-status -i 1.1 -s done
Repeat steps 4.4.1 through 4.4.8 for the next subtask (1.2, 1.3, etc.)
After all subtasks are complete:
# Final linting
pnpm lint
# Final type checking
pnpm typecheck
# Final CodeRabbit review
coderabbit --prompt-only
# Address any remaining issues if critical
# Document final task completion
tm update-task -i 1 --append --prompt="Task 1 - Complete:
- All subtasks completed: [list all subtasks]
- Final verification passed: lint, typecheck, CodeRabbit review
- Files changed: [comprehensive list]
- Committed to brief branch"
tm set-status -i 1 -s done
Note: Do NOT push or create PR yet. Continue to next task in the same branch.
# Verify remaining tasks
tm list
# Continue with next task (e.g., Task 2)
# Repeat steps 4.1 through 4.5 for Task 2, then Task 3, etc.
Continue working through all tasks (Steps 4.1-4.6) until all tasks in the brief are complete. All work is committed to the same hamster-brief branch.
After ALL tasks are complete:
# Verify all tasks are done
tm list
# Should show all tasks with status 'done'
# Final comprehensive checks
pnpm lint
pnpm typecheck
coderabbit --prompt-only
# Address any remaining issues if critical
# Push the brief branch to remote
git push origin hamster-brief
# Get all task titles (adjust task IDs as needed)
# Create comprehensive PR description
gh pr create \
--base dev \
--title "Hamster Brief: Complete Implementation" \
--body "## Brief Overview
Completed all tasks from Hamster brief.
## Tasks Completed
- [x] Task 1: [Task 1 title]
- Subtasks: 1.1, 1.2, 1.3
- [x] Task 2: [Task 2 title]
- Subtasks: 2.1, 2.2
- [x] Task 3: [Task 3 title]
- [Continue listing all tasks]
## Implementation Summary
- Total tasks: [number]
- Total subtasks: [number]
- Files modified: [comprehensive list]
- All quality checks passed
## Quality Checks
- ✅ Linting passed (pnpm lint)
- ✅ Type checking passed (pnpm typecheck)
- ✅ CodeRabbit review completed for all changes
## Testing
- [ ] Manual testing completed
- [ ] All checks passing
Complete implementation of Hamster brief tasks"
# After PR is merged, switch back to dev
git checkout dev
git pull origin dev
# Delete local branch (optional)
git branch -d hamster-brief
tm list, tm show <id>, tm set-status, tm update-task, tm auth refresh, tm context <brief url>hamster-brief)tm update-task -i <id> --append frequently to document:
--base dev when creating PRs1. Verify connection → tm context
2. List tasks → tm list
3. Create single branch → git checkout -b hamster-brief
4. For each task (in same branch):
a. Read task → tm show X
b. Log context → tm update-task -i X --append
c. Mark in-progress → tm set-status -i X,X.Y -s in-progress
d. For each subtask:
- Read → tm show X.Y
- Log context → tm update-task -i X --append
- Implement code
- Verify → pnpm lint && pnpm typecheck
- Review → coderabbit --prompt-only
- Log completion → tm update-task -i X --append
- Commit → git commit (following git_workflow.mdc format)
- Mark done → tm set-status -i X.Y -s done
e. Final checks → pnpm lint && pnpm typecheck && coderabbit --prompt-only
f. Log completion → tm update-task -i X --append
g. Mark task done → tm set-status -i X -s done
h. Continue to next task (same branch)
5. After ALL tasks complete:
a. Final verification → pnpm lint && pnpm typecheck && coderabbit --prompt-only
b. Push branch → git push origin hamster-brief
c. Create PR → gh pr create --base dev