Skip to content

Build README

Build README #1696

Workflow file for this run

name: Build README
on:
push:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
- uses: actions/cache@v3
name: Configure npm caching
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install Node.js dependencies
run: |
npm install
- name: Update README
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |-
node build.js
cat README.md
- name: Commit and push if changed
run: |-
git diff
git config --global user.email "[email protected]"
git config --global user.name "Tw93-bot"
git pull
git add -A
git commit -m "Updated content" || exit 0
git push