chore: restore build workflow #5
Workflow file for this run
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: Migrate code fence metadata | |
| on: | |
| push: | |
| branches: | |
| - agent/semantic-content-figures | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| migrate: | |
| if: github.actor != 'github-actions[bot]' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout branch | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: agent/semantic-content-figures | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 24 | |
| cache: npm | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Migrate Markdown | |
| run: node scripts/migrate-code-fence-meta.mjs | |
| - name: Format files | |
| run: npm run format | |
| - name: Check formatting | |
| run: npm run format:check | |
| - name: Build | |
| run: npm run build | |
| - name: Commit migration | |
| run: | | |
| git config user.name github-actions[bot] | |
| git config user.email 41898282+github-actions[bot]@users.noreply.github.com | |
| git add src/pages src/plugins/rehype-content-figures.ts src/styles/content-figures.css | |
| git diff --cached --quiet || git commit -m "docs: move code captions to fence metadata" | |
| git push |