Update speakers.json from Sessionize #50
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: Update speakers.json from Sessionize | |
| on: | |
| schedule: | |
| # Nightly at 01:17 UTC | |
| - cron: "17 1 * * *" | |
| workflow_dispatch: {} | |
| permissions: | |
| contents: write | |
| concurrency: | |
| group: sessionize-scrape | |
| cancel-in-progress: false | |
| jobs: | |
| scrape: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| token: ${{ secrets.SPEAKERS_BOT_TOKEN }} | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: npm | |
| cache-dependency-path: src/package-lock.json | |
| - name: Install dependencies | |
| working-directory: src | |
| run: npm ci | |
| - name: Run scraper | |
| working-directory: src | |
| run: npm run scrape:sessionize -- --query Zure --in data/speakers.json --out data/speakers.json | |
| - name: Commit and push if changed | |
| run: | | |
| if git diff --quiet; then | |
| echo "No changes" | |
| exit 0 | |
| fi | |
| git status --porcelain | |
| git config user.name "github-actions[bot]" | |
| git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
| git add src/data/speakers.json | |
| git commit -m "chore: update speakers from Sessionize" | |
| git push |