Skip to content

Autocommit

Autocommit #799

Workflow file for this run

name: Autocommit
on:
schedule:
- cron: "0 23 * * *"
workflow_dispatch:
jobs:
autocommit:
if: |
!startsWith(github.event.head_commit.message, 'chore') &&
!startsWith(github.event.head_commit.message, 'build: hotfix') &&
!endsWith(github.event.head_commit.message, 'reformatted by jina-dev-bot')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.JINA_DEV_BOT }}
ref: ${{ github.event.pull_request.head.sha }}
- run: |
git config --local user.email "[email protected]"
git config --local user.name "Jina Dev Bot"
- uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Checkout wall-of-honor
uses: actions/checkout@v2
with:
repository: jina-ai/wall-of-honor
path: wall
token: ${{ secrets.JINA_DEV_BOT }}
- name: Run contributor generation
run: |
cd wall
npm i -D [email protected]
npm list all-contributors-cli
cp patch.js ./node_modules/all-contributors-cli/dist/generate/index.js
cp ../profile/README.md README.md
pip install -r requirements.txt
python app.py config.yml export.yml
cp README.md ../profile/README.md
cd ..
rm -rf wall
git add profile/README.md &> /dev/null || true
git commit -m 'chore(contributor): update contributors' &> /dev/null || true
git status
env:
PRIVATE_TOKEN: ${{ secrets.JINA_DEV_BOT }}
- uses: ad-m/[email protected]
with:
github_token: ${{ secrets.JINA_DEV_BOT }}
branch: main