Skip to content
Permalink
8d0c402e84
Switch branches/tags
View runs Go to file
 
 
Cannot retrieve contributors at this time
46 lines (36 sloc) 1.14 KB
name: Update
on:
push:
branches:
- master
schedule:
- cron: '*/15 * * * *'
workflow_dispatch: {}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Checkout OpenShift Data
uses: actions/checkout@v2
with:
repository: 'openshift/cincinnati-graph-data'
path: cincinnati-graph-data
- name: Update streams
run: .github/scripts/update_streams.sh
- name: Update data
run: .github/scripts/update_data.sh
- name: Commit changes
run: |
git config --global user.name "GitHub update workflow"
git config --global user.email 'ctron@users.noreply.github.com'
git add -A
if ! git diff --cached --exit-code; then
echo "Changes have been detected, commit and push ..."
git commit -am "Automatic update ($GITHUB_RUN_ID/$GITHUB_RUN_NUMBER)"
git log --graph --abbrev-commit --date=relative -n 5
git push
else
echo "No changes have been detected since last build, nothing to publish"
fi