Merge pull request #8 from zunalita/main #4
This file contains hidden or 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 API Map | |
| on: | |
| push: | |
| paths: | |
| - 'api/**.js' | |
| - 'scripts/generate-api-map.js' | |
| workflow_dispatch: | |
| jobs: | |
| generate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: '18' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run generate-api-map.js | |
| run: node scripts/generate-api-map.js | |
| - name: Commit api-map.json if changed | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git add api-map.json | |
| git commit -m "chore: update api-map.json [auto]" | |
| git push |