Generate JSON #16
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: Generate JSON | ||
on: | ||
push: | ||
branches: | ||
- 'master' | ||
paths: | ||
- README.md | ||
- !generated/** | ||
workflow_dispatch: | ||
permissions: | ||
contents: write | ||
pages: write | ||
id-token: write | ||
jobs: | ||
build-manual: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
persist-credentials: false | ||
fetch-depth: 0 | ||
- name: Print commit id, message and tag | ||
run: | | ||
git show -s --format='%h %s' | ||
echo "github.ref -> {{ github.ref }}" | ||
- name: Set up Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 22 | ||
- name: Run script to generate JSON | ||
run: npm run generate | ||
- name: Commit | ||
run: | | ||
git config user.name mazipan | ||
git config user.email [email protected] | ||
git add -A . | ||
git commit -m "CHORE: 🐒 Auto generate JSON" | ||
- name: GitHub Push | ||
uses: ad-m/[email protected] | ||
with: | ||
directory: "." | ||
github_token: ${{ secrets.PAT }} | ||
branch: master |