Skip to content

Update Homebrew Formula #208

Update Homebrew Formula

Update Homebrew Formula #208

name: Update Homebrew Formula
on:
schedule:
- cron: '0 0 * * *' # Runs daily at midnight
workflow_dispatch:
repository_dispatch:
types: [oxy_release]
jobs:
update-formula:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
- name: Run update script
run: ruby scripts/update_formula.rb
- name: Commit changes
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git add Formula/oxy.rb
if git diff --cached --quiet; then
echo "No changes to commit."
else
git commit -m 'chore: update Homebrew formula for new release'
git push
fi
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}