Skip to content

Commit

Permalink
ci: Only run build steps if there are changes
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions committed Oct 23, 2024
1 parent 468f178 commit 756c8b4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ jobs:
if: ${{ steps.fetch_icons.outputs.files_changed == 'true'}}
uses: ./.github/create_code_connect
- name: Create PR title
if: ${{ steps.fetch_icons.outputs.files_changed == 'true'}}
id: title
run: |
if [ ${{github.ref_name=='main'}} ]; then
Expand All @@ -73,6 +74,7 @@ jobs:
git commit -m "${{steps.title.outputs.TITLE}}"
git push --set-upstream origin ${{steps.branch_name.outputs.BRANCH_NAME}} -f
- name: Check if PR exists
if: ${{ steps.fetch_icons.outputs.files_changed == 'true'}}
run: echo "pr_exists=$(gh pr list -H ${{steps.branch_name.outputs.BRANCH_NAME}} --json number -q length)" >> $GITHUB_ENV
env:
GITHUB_TOKEN: ${{ github.token }}
Expand Down

0 comments on commit 756c8b4

Please sign in to comment.