-
Notifications
You must be signed in to change notification settings - Fork 3
36 lines (32 loc) · 1.17 KB
/
update_formula.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# This is a basic workflow that is manually triggered
name: Update Formula
# Run when a release is published to update the hombrew formula
on:
release:
types: [released]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
update:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: checkout with actions/checkout@v3
uses: actions/checkout@v3
with:
repository: OneSignal/cli
- name: run update_formula.py
run: |
echo ${{ github.ref_name }}
echo ${{ github.sha }}
python3 ./.github/workflows/update_formula.py ${{ github.ref_name }} ${{ github.sha }}
- name: Commit files onesignal-cli.rb
run: |
git config --local user.name ${{ github.actor }}
git add .
git commit -m "Updating the onesignal-cli formula for the latest release"
- name: Push changes # push the output folder to your repo
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
force: true