You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Simplify commit job file review to agent self-verification (#82)
Changed the commit_and_push step to verify files match the agent's own
expectations instead of asking the user every time. This reduces unnecessary
interruptions while still catching unexpected changes.
Co-authored-by: Claude <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: .claude/skills/commit.commit_and_push/SKILL.md
+22-27Lines changed: 22 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,15 @@
1
1
---
2
2
name: commit.commit_and_push
3
-
description: "Review changed files, commit, and push to remote"
3
+
description: "Verify changed files, commit, and push to remote"
4
4
user-invocable: false
5
5
hooks:
6
6
Stop:
7
7
- hooks:
8
8
- type: prompt
9
9
prompt: |
10
10
Verify the commit is ready:
11
-
1. Changed files list was reviewed with user
12
-
2. User confirmed the files match expectations
11
+
1. Changed files list was reviewed by the agent
12
+
2. Files match what was modified during this session (or unexpected changes were investigated)
13
13
3. Commit was created with appropriate message
14
14
4. Changes were pushed to remote
15
15
If ALL criteria are met, include `<promise>✓ Quality Criteria Met</promise>`.
@@ -29,17 +29,17 @@ Before proceeding, confirm these steps are complete:
29
29
30
30
## Instructions
31
31
32
-
**Goal**: Review changed files, commit, and push to remote
32
+
**Goal**: Verify changed files, commit, and push to remote
33
33
34
34
# Commit and Push
35
35
36
36
## Objective
37
37
38
-
Review the changed files with the user, create a commit with an appropriate message, and push to the remote repository.
38
+
Review the changed files to verify they match the agent's expectations, create a commit with an appropriate message, and push to the remote repository.
39
39
40
40
## Task
41
41
42
-
Present the list of changed files for user review, ensure they match expectations, then commit and push the changes.
42
+
Check the list of changed files against what was modified during this session, ensure they match expectations, then commit and push the changes.
43
43
44
44
### Process
45
45
@@ -49,31 +49,26 @@ Present the list of changed files for user review, ensure they match expectation
49
49
```
50
50
Also run `git diff --stat` to see a summary of changes.
51
51
52
-
2.**Present changes to the user for review**
52
+
2.**Verify changes match expectations**
53
53
54
-
Use the AskUserQuestion tool to ask structured questions about the changes:
54
+
Compare the changed files against what you modified during this session:
55
+
- Do the modified files match what you edited?
56
+
- Are there any unexpected new files?
57
+
- Are there any unexpected deleted files?
58
+
- Do the line counts seem reasonable for the changes you made?
55
59
56
-
Show the user:
57
-
- List of modified files
58
-
- List of new files
59
-
- List of deleted files
60
-
- Summary of changes (lines added/removed)
60
+
If changes match expectations, proceed to commit.
61
61
62
-
Ask them to confirm:
63
-
- "Do these changed files match your expectations?"
64
-
- Provide options: "Yes, proceed with commit" / "No, let me review first" / "No, some files shouldn't be included"
- If they're legitimate side effects of your work, include them
65
+
- If they're unrelated or shouldn't be committed, use `git restore` to discard them
65
66
66
-
3.**Handle user response**
67
-
68
-
- If user confirms, proceed to commit
69
-
- If user wants to review first, wait for them to come back
70
-
- If user says some files shouldn't be included, ask which files to exclude and use `git restore` or `git checkout` to unstage them
71
-
72
-
4.**Stage all appropriate changes**
67
+
3.**Stage all appropriate changes**
73
68
```bash
74
69
git add -A
75
70
```
76
-
Or stage specific files if user excluded some.
71
+
Or stage specific files if some were excluded.
77
72
78
73
5.**View recent commit messages for style reference**
79
74
```bash
@@ -102,16 +97,16 @@ Present the list of changed files for user review, ensure they match expectation
102
97
103
98
## Quality Criteria
104
99
105
-
- Changed files list was presented to user
106
-
-User explicitly confirmed the files match expectations
100
+
- Changed files list was reviewed by the agent
101
+
-Files match what was modified during this session (or unexpected changes were investigated and handled)
107
102
- Commit message follows project conventions
108
103
- Commit was created successfully
109
104
- Changes were pushed to remote
110
105
- When all criteria are met, include `<promise>✓ Quality Criteria Met</promise>` in your response
111
106
112
107
## Context
113
108
114
-
This is the final step of the commit workflow. It ensures the user has reviewed and approved the changes before they are committed and pushed. This prevents accidental commits of unintended files or changes.
109
+
This is the final step of the commit workflow. The agent verifies that the changed files match its own expectations from the work done during the session, then commits and pushes. This catches unexpected changes while avoiding unnecessary user interruptions.
Copy file name to clipboardExpand all lines: .deepwork/jobs/commit/job.yml
+6-4Lines changed: 6 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
name: commit
2
-
version: "1.0.0"
2
+
version: "1.0.1"
3
3
summary: "Run tests, lint, and commit code changes"
4
4
description: |
5
5
A workflow for preparing and committing code changes with quality checks.
@@ -14,6 +14,8 @@ description: |
14
14
3. commit_and_push - Review changes and commit/push
15
15
16
16
changelog:
17
+
- version: "1.0.1"
18
+
changes: "Changed file review from user confirmation to agent self-verification - agent now checks files match its own expectations instead of asking user every time"
17
19
- version: "1.0.0"
18
20
changes: "Initial job creation"
19
21
@@ -56,7 +58,7 @@ steps:
56
58
57
59
- id: commit_and_push
58
60
name: "Commit and Push"
59
-
description: "Review changed files, commit, and push to remote"
61
+
description: "Verify changed files, commit, and push to remote"
60
62
instructions_file: steps/commit_and_push.md
61
63
inputs: []
62
64
outputs: []
@@ -66,8 +68,8 @@ steps:
66
68
after_agent:
67
69
- prompt: |
68
70
Verify the commit is ready:
69
-
1. Changed files list was reviewed with user
70
-
2. User confirmed the files match expectations
71
+
1. Changed files list was reviewed by the agent
72
+
2. Files match what was modified during this session (or unexpected changes were investigated)
71
73
3. Commit was created with appropriate message
72
74
4. Changes were pushed to remote
73
75
If ALL criteria are met, include `<promise>✓ Quality Criteria Met</promise>`.
Copy file name to clipboardExpand all lines: .deepwork/jobs/commit/steps/commit_and_push.md
+18-23Lines changed: 18 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,11 +2,11 @@
2
2
3
3
## Objective
4
4
5
-
Review the changed files with the user, create a commit with an appropriate message, and push to the remote repository.
5
+
Review the changed files to verify they match the agent's expectations, create a commit with an appropriate message, and push to the remote repository.
6
6
7
7
## Task
8
8
9
-
Present the list of changed files for user review, ensure they match expectations, then commit and push the changes.
9
+
Check the list of changed files against what was modified during this session, ensure they match expectations, then commit and push the changes.
10
10
11
11
### Process
12
12
@@ -16,31 +16,26 @@ Present the list of changed files for user review, ensure they match expectation
16
16
```
17
17
Also run `git diff --stat` to see a summary of changes.
18
18
19
-
2.**Present changes to the user for review**
19
+
2.**Verify changes match expectations**
20
20
21
-
Use the AskUserQuestion tool to ask structured questions about the changes:
21
+
Compare the changed files against what you modified during this session:
22
+
- Do the modified files match what you edited?
23
+
- Are there any unexpected new files?
24
+
- Are there any unexpected deleted files?
25
+
- Do the line counts seem reasonable for the changes you made?
22
26
23
-
Show the user:
24
-
- List of modified files
25
-
- List of new files
26
-
- List of deleted files
27
-
- Summary of changes (lines added/removed)
27
+
If changes match expectations, proceed to commit.
28
28
29
-
Ask them to confirm:
30
-
- "Do these changed files match your expectations?"
31
-
- Provide options: "Yes, proceed with commit" / "No, let me review first" / "No, some files shouldn't be included"
- If they're legitimate side effects of your work, include them
32
+
- If they're unrelated or shouldn't be committed, use `git restore` to discard them
32
33
33
-
3.**Handle user response**
34
-
35
-
- If user confirms, proceed to commit
36
-
- If user wants to review first, wait for them to come back
37
-
- If user says some files shouldn't be included, ask which files to exclude and use `git restore` or `git checkout` to unstage them
38
-
39
-
4.**Stage all appropriate changes**
34
+
3.**Stage all appropriate changes**
40
35
```bash
41
36
git add -A
42
37
```
43
-
Or stage specific files if user excluded some.
38
+
Or stage specific files if some were excluded.
44
39
45
40
5.**View recent commit messages for style reference**
46
41
```bash
@@ -69,13 +64,13 @@ Present the list of changed files for user review, ensure they match expectation
69
64
70
65
## Quality Criteria
71
66
72
-
- Changed files list was presented to user
73
-
-User explicitly confirmed the files match expectations
67
+
- Changed files list was reviewed by the agent
68
+
-Files match what was modified during this session (or unexpected changes were investigated and handled)
74
69
- Commit message follows project conventions
75
70
- Commit was created successfully
76
71
- Changes were pushed to remote
77
72
- When all criteria are met, include `<promise>✓ Quality Criteria Met</promise>` in your response
78
73
79
74
## Context
80
75
81
-
This is the final step of the commit workflow. It ensures the user has reviewed and approved the changes before they are committed and pushed. This prevents accidental commits of unintended files or changes.
76
+
This is the final step of the commit workflow. The agent verifies that the changed files match its own expectations from the work done during the session, then commits and pushes. This catches unexpected changes while avoiding unnecessary user interruptions.
Copy file name to clipboardExpand all lines: .gemini/skills/commit/commit_and_push.toml
+21-26Lines changed: 21 additions & 26 deletions
Original file line number
Diff line number
Diff line change
@@ -1,10 +1,10 @@
1
1
# commit:commit_and_push
2
2
#
3
-
#Review changed files, commit, and push to remote
3
+
#Verify changed files, commit, and push to remote
4
4
#
5
5
# Generated by DeepWork - do not edit manually
6
6
7
-
description = "Review changed files, commit, and push to remote"
7
+
description = "Verify changed files, commit, and push to remote"
8
8
9
9
prompt = """
10
10
# commit:commit_and_push
@@ -20,17 +20,17 @@ Before proceeding, confirm these steps are complete:
20
20
21
21
## Instructions
22
22
23
-
**Goal**: Review changed files, commit, and push to remote
23
+
**Goal**: Verify changed files, commit, and push to remote
24
24
25
25
# Commit and Push
26
26
27
27
## Objective
28
28
29
-
Review the changed files with the user, create a commit with an appropriate message, and push to the remote repository.
29
+
Review the changed files to verify they match the agent's expectations, create a commit with an appropriate message, and push to the remote repository.
30
30
31
31
## Task
32
32
33
-
Present the list of changed files for user review, ensure they match expectations, then commit and push the changes.
33
+
Check the list of changed files against what was modified during this session, ensure they match expectations, then commit and push the changes.
34
34
35
35
### Process
36
36
@@ -40,31 +40,26 @@ Present the list of changed files for user review, ensure they match expectation
40
40
```
41
41
Also run `git diff --stat` to see a summary of changes.
42
42
43
-
2. **Present changes to the user for review**
43
+
2. **Verify changes match expectations**
44
44
45
-
Use the AskUserQuestion tool to ask structured questions about the changes:
45
+
Compare the changed files against what you modified during this session:
46
+
- Do the modified files match what you edited?
47
+
- Are there any unexpected new files?
48
+
- Are there any unexpected deleted files?
49
+
- Do the line counts seem reasonable for the changes you made?
46
50
47
-
Show the user:
48
-
- List of modified files
49
-
- List of new files
50
-
- List of deleted files
51
-
- Summary of changes (lines added/removed)
51
+
If changes match expectations, proceed to commit.
52
52
53
-
Ask them to confirm:
54
-
- "Do these changed files match your expectations?"
55
-
- Provide options: "Yes, proceed with commit" / "No, let me review first" / "No, some files shouldn't be included"
- If they're legitimate side effects of your work, include them
56
+
- If they're unrelated or shouldn't be committed, use `git restore` to discard them
56
57
57
-
3. **Handle user response**
58
-
59
-
- If user confirms, proceed to commit
60
-
- If user wants to review first, wait for them to come back
61
-
- If user says some files shouldn't be included, ask which files to exclude and use `git restore` or `git checkout` to unstage them
62
-
63
-
4. **Stage all appropriate changes**
58
+
3. **Stage all appropriate changes**
64
59
```bash
65
60
git add -A
66
61
```
67
-
Or stage specific files if user excluded some.
62
+
Or stage specific files if some were excluded.
68
63
69
64
5. **View recent commit messages for style reference**
70
65
```bash
@@ -93,16 +88,16 @@ Present the list of changed files for user review, ensure they match expectation
93
88
94
89
## Quality Criteria
95
90
96
-
- Changed files list was presented to user
97
-
- User explicitly confirmed the files match expectations
91
+
- Changed files list was reviewed by the agent
92
+
- Files match what was modified during this session (or unexpected changes were investigated and handled)
98
93
- Commit message follows project conventions
99
94
- Commit was created successfully
100
95
- Changes were pushed to remote
101
96
- When all criteria are met, include `<promise>✓ Quality Criteria Met</promise>` in your response
102
97
103
98
## Context
104
99
105
-
This is the final step of the commit workflow. It ensures the user has reviewed and approved the changes before they are committed and pushed. This prevents accidental commits of unintended files or changes.
100
+
This is the final step of the commit workflow. The agent verifies that the changed files match its own expectations from the work done during the session, then commits and pushes. This catches unexpected changes while avoiding unnecessary user interruptions.
0 commit comments