@@ -149,7 +149,7 @@ runs:
149
149
commit_user_email :
[email protected]
150
150
151
151
- name : Append success comment
152
- if : inputs.pr && steps.auto-commit.outputs.changes_detected == 'true'
152
+ if : steps.comment-start.outputs.comment-id && steps.auto-commit.outputs.changes_detected == 'true'
153
153
uses : peter-evans/create-or-update-comment@v4
154
154
with :
155
155
comment-id : ${{ steps.comment-start.outputs.comment-id }}
@@ -158,7 +158,7 @@ runs:
158
158
✅ Poe command `${{ steps.resolve-command.outputs.command }}` completed successfully.
159
159
160
160
- name : Append no-op comment
161
- if : inputs.pr && steps.auto-commit.outputs.changes_detected != 'true'
161
+ if : steps.comment-start.outputs.comment-id && steps.auto-commit.outputs.changes_detected != 'true'
162
162
uses : peter-evans/create-or-update-comment@v4
163
163
with :
164
164
comment-id : ${{ steps.comment-start.outputs.comment-id }}
@@ -167,7 +167,7 @@ runs:
167
167
🟦 Poe command `${{ steps.resolve-command.outputs.command }}` completed successfully. (No changes.)
168
168
169
169
- name : Append failure comment
170
- if : failure() && inputs.pr
170
+ if : failure() && steps.comment-start.outputs.comment-id
171
171
uses : peter-evans/create-or-update-comment@v4
172
172
with :
173
173
comment-id : ${{ steps.comment-start.outputs.comment-id }}
@@ -179,6 +179,7 @@ runs:
179
179
180
180
- name : Create Pull Request
181
181
if : ${{ ! inputs.pr }}
182
+ id : create-pr
182
183
uses : peter-evans/create-pull-request@v7
183
184
with :
184
185
title : " Auto-generated PR: `poe ${{ steps.resolve-command.outputs.command }}`"
@@ -198,3 +199,13 @@ runs:
198
199
commit-user-name : Octavia Squidington III
199
200
commit-user-email :
[email protected]
200
201
token : ${{ inputs.github-token }}
202
+
203
+ - name : Append PR link to comment
204
+ if : ${{ steps.comment-start.outputs.comment-id && ! inputs.pr && steps.create-pr.outputs.pull-request-url }}
205
+ uses : peter-evans/create-or-update-comment@v4
206
+ with :
207
+ comment-id : ${{ steps.comment-start.outputs.comment-id }}
208
+ body : >
209
+ > 🚀 PR Created:
210
+ >
211
+ > - ${{ steps.create-pr.outputs.pull-request-url }}
0 commit comments