Updates OpenEBS Contributor list #1222
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: Updates OpenEBS Contributor list | |
on: | |
schedule: | |
# Runs at every 00:00 | |
- cron: "0 0 * * *" | |
workflow_dispatch: | |
jobs: | |
resources: | |
name: Update resources | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: main | |
- name: Use Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: "16" | |
- name: install dep | |
run: npm install request | |
# Getting the contributors list from node script | |
- name: Get contributors | |
working-directory: ./scripts | |
run: npm run get-contributors-info | |
- name: Commit the changes | |
run: | | |
git status | |
git config user.name github-actions | |
git config user.email [email protected] | |
git add '*/topContributors.json' '*/newContributors.json' | |
git diff-index --quiet HEAD || (git commit -s -a -m'[bot] update contributor list' --allow-empty && git push -f) |