Skip to content

Commit 72e9e1c

Browse files
authored
Merge pull request #15 from youennf/add-workflow
Add workflow to auto generate html and txt versions of the spec in gh-pages branch
2 parents 9bc881e + fa6d5a1 commit 72e9e1c

File tree

3 files changed

+60
-1549
lines changed

3 files changed

+60
-1549
lines changed

.github/workflows/ghpages.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: "Update Editor's Copy"
2+
3+
on:
4+
push:
5+
paths-ignore:
6+
- README.md
7+
- CONTRIBUTING.md
8+
- LICENSE.md
9+
- .gitignore
10+
pull_request:
11+
paths-ignore:
12+
- README.md
13+
- CONTRIBUTING.md
14+
- LICENSE.md
15+
- .gitignore
16+
17+
jobs:
18+
build:
19+
name: "Update Editor's Copy"
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: "Checkout"
23+
uses: actions/checkout@v4
24+
25+
- name: "Cache Setup"
26+
id: cache-setup
27+
run: |
28+
mkdir -p "$HOME"/.cache/xml2rfc
29+
echo "::set-output name=path::$HOME/.cache/xml2rfc"
30+
date -u "+::set-output name=date::%FT%T"
31+
32+
- name: "Cache References"
33+
uses: actions/cache@v4
34+
with:
35+
path: |
36+
${{ steps.cache-setup.outputs.path }}
37+
.targets.mk
38+
key: refcache-${{ steps.cache-setup.outputs.date }}
39+
restore-keys: |
40+
refcache-${{ steps.cache-setup.outputs.date }}
41+
refcache-
42+
43+
- name: "Build Drafts"
44+
uses: martinthomson/i-d-template@v1
45+
with:
46+
token: ${{ github.token }}
47+
48+
- name: "Update GitHub Pages"
49+
uses: martinthomson/i-d-template@v1
50+
if: ${{ github.event_name == 'push' }}
51+
with:
52+
make: gh-pages
53+
token: ${{ github.token }}
54+
55+
- name: "Archive Built Drafts"
56+
uses: actions/upload-artifact@v4
57+
with:
58+
path: |
59+
draft-*.html
60+
draft-*.txt

0 commit comments

Comments
 (0)