build SPECURLS.json #1301
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: build SPECURLS.json | |
on: | |
schedule: | |
- cron: '49 2 * * *' | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
build: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: 19 | |
- name: Run SPECURLS.json build | |
id: incoming | |
run: | | |
echo "conclusion=success" >> $GITHUB_OUTPUT | |
make URLS-LOG \ | |
|| echo "conclusion=failure" >> $GITHUB_OUTPUT | |
- uses: crazy-max/ghaction-import-gpg@v3 | |
with: | |
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }} | |
passphrase: ${{ secrets.GPG_SIGNING_KEY_PASSPHRASE }} | |
git-user-signingkey: true | |
git-commit-gpgsign: true | |
- name: Create pull request | |
id: cpr | |
uses: peter-evans/create-pull-request@v3 | |
with: | |
title: Update SPECURLS.json | |
commit-message: Update SPECURLS.json | |
committer: sideshowbarkerbot <[email protected]> | |
author: sideshowbarkerbot <[email protected]> | |
assignees: sideshowbarker | |
reviewers: sideshowbarker | |
branch: create-pull-request/patch-spec-urls | |
delete-branch: true | |
- name: Log pull request URL | |
run: | | |
echo "Pull request URL: ${{ steps.cpr.outputs.pull-request-url }}" | |
- name: Set status | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
curl \ | |
-X POST \ | |
-H "Authorization: Bearer $GITHUB_TOKEN" \ | |
-H "Accept: application/vnd.github.v3+json" \ | |
https://api.github.com/repos/w3c/mdn-spec-links/statuses/${{ github.sha }} \ | |
-d '{"state": "success", "context": "Update SPECURLS.json" }' | |
make report-only || true | |
if [[ "${{ steps.build.outputs.conclusion }}" == "failure" ]]; then exit 1; fi |