Skip to content

Commit

Permalink
skip all steps if labeled as published
Browse files Browse the repository at this point in the history
  • Loading branch information
j-i-l committed May 19, 2024
1 parent 5872187 commit 121fca5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
12 changes: 7 additions & 5 deletions .github/workflows/publish_version_enforce.yml
Original file line number Diff line number Diff line change
Expand Up @@ -175,17 +175,14 @@ jobs:
--title "${{ steps.release_version.outputs.version }}" \
--notes-file body.md \
--repo ${{ env.OWNER }}/${{ env.REPO }} \
- name: Adding the label ${{ env.LABEL_PUBLISHED }} # 2
if: ${{ (steps.published.outputs.labeled == 'false') }}
run: |
gh pr edit ${{ needs.associated_pr.outputs.event }} --add-label ${{ env.LABEL_PUBLISHED }} --repo ${{ env.OWNER }}/${{ env.REPO }}
shell: bash
- name: Get the built package
if: ${{ (steps.published.outputs.labeled == 'false') }}
uses: actions/download-artifact@v4
with:
name:
package
- name: Upload additional artifacts to the release
if: ${{ (steps.published.outputs.labeled == 'false') }}
run: |
gh release upload ${{ steps.release_version.outputs.version }} \
./abn.tar.gz \
Expand All @@ -194,3 +191,8 @@ jobs:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
- name: Adding the label ${{ env.LABEL_PUBLISHED }} # 2
if: ${{ (steps.published.outputs.labeled == 'false') }}
run: |
gh pr edit ${{ needs.associated_pr.outputs.event }} --add-label ${{ env.LABEL_PUBLISHED }} --repo ${{ env.OWNER }}/${{ env.REPO }}
shell: bash
12 changes: 7 additions & 5 deletions .github/workflows/publish_version_merging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,17 +143,14 @@ jobs:
--title "${{ steps.release_version.outputs.version }}" \
--notes-file body.md \
--repo ${{ env.OWNER }}/${{ env.REPO }}
- name: Adding the label ${{ env.LABEL_PUBLISHED }}
if: ${{ steps.published.outputs.labeled == 'false' }}
run: |
gh pr edit ${{ env.EVENT }} --add-label ${{ env.LABEL_PUBLISHED }} --repo ${{ env.OWNER }}/${{ env.REPO }}
shell: bash
- name: Get the built package
if: ${{ steps.published.outputs.labeled == 'false' }}
uses: actions/download-artifact@v4
with:
name:
package
- name: Upload additional artifacts to the release
if: ${{ steps.published.outputs.labeled == 'false' }}
run: |
gh release upload ${{ steps.release_version.outputs.version }} \
./abn.tar.gz \
Expand All @@ -162,3 +159,8 @@ jobs:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
- name: Adding the label ${{ env.LABEL_PUBLISHED }}
if: ${{ steps.published.outputs.labeled == 'false' }}
run: |
gh pr edit ${{ env.EVENT }} --add-label ${{ env.LABEL_PUBLISHED }} --repo ${{ env.OWNER }}/${{ env.REPO }}
shell: bash

0 comments on commit 121fca5

Please sign in to comment.