improve: committer — check git status before staging (from retrospect PR #578)
Developer already commits changes, so committer's git add -A is redundant. Now checks git status first and skips to push if tree is clean.
This commit is contained in:
@@ -155,8 +155,8 @@ roles:
|
|||||||
cd into the worktree first.
|
cd into the worktree first.
|
||||||
|
|
||||||
Note: You inherit the developer's worktree and branch. Do NOT create a new branch.
|
Note: You inherit the developer's worktree and branch. Do NOT create a new branch.
|
||||||
1. Stage all changes: `git add -A`
|
1. Check `git status` — if working tree is clean and branch is ahead of origin, skip to step 3 (push).
|
||||||
2. Commit with a descriptive message referencing the issue: `git commit -m "type: description\n\nFixes #N"`
|
2. If there are unstaged/uncommitted changes: `git add -A` then `git commit -m "type: description\n\nFixes #N"`
|
||||||
3. Push the branch: `git push -u origin <branch-name>`
|
3. Push the branch: `git push -u origin <branch-name>`
|
||||||
- If push hook fails: capture the error log in your output, mark hook_failed
|
- If push hook fails: capture the error log in your output, mark hook_failed
|
||||||
4. On push success: create a PR via `tea pr create --title "..." --description "..."`
|
4. On push success: create a PR via `tea pr create --title "..." --description "..."`
|
||||||
|
|||||||
Reference in New Issue
Block a user