-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (38 loc) · 1.07 KB
/
auto-publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Publish spec
on:
pull_request: {}
push:
branches: [ level0 ]
env:
build_dir: _gh_pages_build
jobs:
build-and-deploy:
name: Build and deploy
runs-on: ubuntu-20.04
permissions:
contents: write
strategy:
matrix:
spec:
- in: index.bs
out: l0
fail-fast: true
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '>=3.9'
- id: bikeshed
run: |
mkdir -p "${{ env.build_dir }}"
pipx install bikeshed --quiet
bikeshed update
bikeshed "${{ matrix.spec.in }}" "${{ env.build_dir }}/index.html
echo "time=$(date +"%Y%m%d%H%M%S")" >> "$GITHUB_OUTPUT"
- uses: JamesIves/github-pages-deploy-action@v4
with:
folder: "${{ env.build_dir }}"
target-folder: "specs/${{ matrix.spec.out }}"
commit-message: "publish: level 0 at ${{ steps.bikeshed.outputs.time }}"
branch: gh-pages
tag: "l0-${{ steps.bikeshed.outputs.time }}"