Close a ticket after work is done — verify tests, commit, push, create PR. Use when the user has finished fixing a bug or implementing a feature.
Level: L0 — Sequential checklist execution
Verify that work is complete, then commit, push, and create a pull request. This is the final step after a bug fix or feature implementation.
pom.xml and/or package.json)mvn test for Java projectsng build for Angular projects/fix. Do not proceed.## Pre-close Verification
- Java tests: 42 passed, 0 failed — OK
- Angular build: Succeeded — OK
TICKET.md if it exists## Acceptance Criteria
- [x] getAllInvoices returns empty list for no data
- [x] getInvoiceById returns 404 for missing invoice
- [x] createInvoice validates required fields
All criteria met — OK
git status --short to see all changesgit diff --stat to see what has been modified## Changes
- Modified: 2 files
- src/main/java/com/botree/invoice/InvoiceService.java
- src/main/java/com/botree/invoice/InvoiceController.java
- Untracked: 0 files
- Staged: 0 files
If there are uncommitted changes:
git diff summarySuggested commit:
git add -A && git commit -m "fix(invoice): return empty list instead of null for getAllInvoices
Resolves BOT-123"
Proceed? (Yes / Modify message / Skip)
git rev-parse --abbrev-ref @{upstream} 2>/dev/nullgit branch --show-currentgit push -u origin {branch}git push origin {branch}## Push
- Branch: feature/BOT-123-fix-null-pointer
- Pushed to: origin/feature/BOT-123-fix-null-pointer
- Status: OK
gh pr view --json number,url 2>/dev/nullSuggested PR:
Title: fix(invoice): return empty list instead of null for getAllInvoices
Body: Resolves BOT-123. Fixed NullPointerException in InvoiceService.getAllInvoices
by returning Collections.emptyList() instead of null.
Create this PR? (Yes / Modify / Skip)
gh pr create --title "..." --body "..."## Ticket Closed
- Ticket: BOT-123
- Branch: feature/BOT-123-fix-null-pointer
- Tests: 42 passed, 0 failed
- Commit: abc1234 — fix(invoice): return empty list instead of null
- PR: https://github.com/botree/invoice-service/pull/7
- Status: Ready for review
| Failure | Detection | Response |
|---|---|---|
| Tests failing | mvn test or ng build reports failures | STOP. Report failures. Suggest /fix. Do not proceed with close. |
| Acceptance criteria not met | TICKET.md criteria not satisfied by test results | STOP. Report which criteria are unmet. Suggest what to fix. |
| Uncommitted changes | git status shows modified/untracked files | Prompt user to commit. Show suggested commit message. |
| No remote configured | git remote -v returns empty | Report: "No remote configured. Add a remote with git remote add origin <url>." |
| gh not authenticated | gh auth status fails | Report: "GitHub CLI not authenticated. Run gh auth login first." |
| PR already exists | gh pr view returns a PR | Report existing PR URL. Skip PR creation. |
| Not on a feature branch | Branch is main or master | STOP. Report: "You are on the main branch. Create a feature branch first." |
| Push rejected | git push fails (diverged, permissions) | Report the error. Suggest git pull --rebase origin {branch} if diverged. |
git push --force) under any circumstances/fix./close for each.After /close completes:
/fix to resolve failures first/onboard to verify setup