Skip to content

Update Counters

Update Counters #7

name: Update Counters
on:
schedule:
- cron: '05 22 1 * *' # This triggers at 21:30 (Paris time) on the first day of each month
jobs:
update_counters:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '18'
- name: Install Dependencies
run: npm install
- name: Run Update Counters Script
run: node .github/scripts/update-counters.js
- name: Create New Branch
run: |
git config --global user.name 'benoitdemaegdt'
git config --global user.email 'benoit.demaegdt@gmail.com'
git add -A
git commit -m "Update counters"
git push
# - name: Create Pull Request
# uses: peter-evans/create-pull-request@v3
# with:
# token: ${{ secrets.GITHUB_TOKEN }}
# branch: update-counters-${{ github.run_id }}
# base: main
# title: "Update Counters"
# body: "Automated update of counters."