Merge pull request #1826 from VitamintK/patch-1 #1515
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update AoC badge | |
on: | |
push: | |
schedule: | |
- cron: '0 0 * 1-11 1' | |
- cron: '0 * * 12 *' | |
jobs: | |
update: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.ref }} | |
fetch-depth: 0 | |
- name: Install packages | |
run: yarn | |
working-directory: ./.github/actions/update-badge | |
- name: Use local action | |
uses: ./.github/actions/update-badge | |
with: | |
ghToken: ${{ secrets.GITHUB_TOKEN }} | |
inputFile: README.md | |
outputFile: README.md | |
- name: Git commit and push | |
run: | | |
git config user.email '[email protected]' | |
git config user.name 'github-actions' | |
if git commit -am 'update badges'; then | |
git push origin HEAD:${{ github.ref }} | |
fi |