File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 77
77
echo "Not interested in this action, skipping"
78
78
exit 0
79
79
fi
80
+
81
+ # Exit if the issue already has an OWS label.
82
+ # TODO: Support updates to Jira issues.
83
+ for label in "${{ github.event.issue.labels.*.name }}"; do
84
+ if [[ "$label" == OWS* ]]; then
85
+ echo "Issue has a label starting with OWS, skipping"
86
+ exit 0
87
+ fi
88
+ done
80
89
81
90
# last one wins
82
91
echo "NeedsJiraUpdate=true" >> $GITHUB_ENV
@@ -235,6 +244,7 @@ runs:
235
244
echo "Linked jira issue ${{ steps.create_jira_issue.outputs.jira_issue_key }} to jira epic ${{ inputs.JIRA_EPIC_KEY }}"
236
245
237
246
- name : Adding label to GitHub issue
247
+ if : ${{ env.NeedsJiraUpdate == 'true' }}
238
248
shell : bash
239
249
run : |
240
250
issue_number=${{ github.event.issue.number }}
@@ -249,6 +259,7 @@ runs:
249
259
"https://api.github.com/repos/${owner}/${repo}/issues/${issue_number}/labels"
250
260
251
261
- name : Remove specific label from issue
262
+ if : ${{ env.NeedsJiraUpdate == 'true' }}
252
263
shell : bash
253
264
run : |
254
265
label_to_remove="${{ inputs.label }}"
You can’t perform that action at this time.
0 commit comments