Skip to content

Commit 29d1b6e

Browse files
committed
fix: ci?
1 parent b2453ba commit 29d1b6e

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

.github/workflows/release.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ on:
1414
jobs:
1515
update-formula:
1616
runs-on: ubuntu-latest
17-
1817
steps:
1918
- name: Extract version from input or release
2019
id: extract_version
@@ -84,13 +83,18 @@ jobs:
8483
8584
echo "Updated formula with version=${NEW_VERSION}, url=${NEW_URL}, sha256=${NEW_SHA256}"
8685
cat $FORMULA_PATH
87-
86+
- name: Show updated formula
87+
run: cat Formula/skidfuscator.rb
8888
- name: Commit and push changes
8989
run: |
90-
git config user.name "github-actions"
91-
git config user.email "[email protected]"
92-
git add Formula/skidfuscator.rb
93-
git commit -m "Update Skidfuscator formula to version ${{ steps.extract_version.outputs.version }}"
94-
git push origin HEAD:main
90+
if [[ -n "$(git status --porcelain)" ]]; then
91+
git config user.name "github-actions"
92+
git config user.email "[email protected]"
93+
git add Formula/skidfuscator.rb
94+
git commit -m "Update Skidfuscator formula to version ${{ steps.extract_version.outputs.version }}"
95+
git push origin HEAD:main
96+
else
97+
echo "No changes to commit"
98+
fi
9599
env:
96100
GITHUB_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}

0 commit comments

Comments
 (0)