Skip to content

Commit f72a781

Browse files
authored
Merge pull request #42 from marten-seemann/update-template
ci: update workflows
2 parents 2c8ff03 + c182d98 commit f72a781

File tree

6 files changed

+29
-13
lines changed

6 files changed

+29
-13
lines changed

.github/workflows/archive.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,11 @@ jobs:
1616
build:
1717
name: "Archive Issues and Pull Requests"
1818
runs-on: ubuntu-latest
19+
permissions:
20+
contents: write
1921
steps:
2022
- name: "Checkout"
21-
uses: actions/checkout@v2
23+
uses: actions/checkout@v4
2224

2325
# Note: No caching for this build!
2426

@@ -37,6 +39,6 @@ jobs:
3739
token: ${{ github.token }}
3840

3941
- name: "Save Archive"
40-
uses: actions/upload-artifact@v3
42+
uses: actions/upload-artifact@v4
4143
with:
4244
path: archive.json

.github/workflows/ghpages.yml

+5-3
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,18 @@ jobs:
1818
build:
1919
name: "Update Editor's Copy"
2020
runs-on: ubuntu-latest
21+
permissions:
22+
contents: write
2123
steps:
2224
- name: "Checkout"
23-
uses: actions/checkout@v3
25+
uses: actions/checkout@v4
2426

2527
- name: "Setup"
2628
id: setup
2729
run: date -u "+date=%FT%T" >>"$GITHUB_OUTPUT"
2830

2931
- name: "Caching"
30-
uses: actions/cache@v3
32+
uses: actions/cache@v4
3133
with:
3234
path: |
3335
.refcache
@@ -51,7 +53,7 @@ jobs:
5153
token: ${{ github.token }}
5254

5355
- name: "Archive Built Drafts"
54-
uses: actions/upload-artifact@v3
56+
uses: actions/upload-artifact@v4
5557
with:
5658
path: |
5759
draft-*.html

.github/workflows/publish.yml

+11-3
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,20 @@ on:
44
push:
55
tags:
66
- "draft-*"
7+
workflow_dispatch:
8+
inputs:
9+
email:
10+
description: "Submitter email"
11+
default: ""
12+
type: string
713

814
jobs:
915
build:
1016
name: "Publish New Draft Version"
1117
runs-on: ubuntu-latest
1218
steps:
1319
- name: "Checkout"
14-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
1521

1622
# See https://github.com/actions/checkout/issues/290
1723
- name: "Get Tag Annotations"
@@ -22,7 +28,7 @@ jobs:
2228
run: date -u "+date=%FT%T" >>"$GITHUB_OUTPUT"
2329

2430
- name: "Caching"
25-
uses: actions/cache@v3
31+
uses: actions/cache@v4
2632
with:
2733
path: |
2834
.refcache
@@ -42,8 +48,10 @@ jobs:
4248
uses: martinthomson/i-d-template@v1
4349
with:
4450
make: upload
51+
env:
52+
UPLOAD_EMAIL: ${{ inputs.email }}
4553

4654
- name: "Archive Submitted Drafts"
47-
uses: actions/upload-artifact@v3
55+
uses: actions/upload-artifact@v4
4856
with:
4957
path: "versioned/draft-*-[0-9][0-9].*"

.github/workflows/update.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
runs-on: ubuntu-latest
2525
steps:
2626
- name: "Checkout"
27-
uses: actions/checkout@v2
27+
uses: actions/checkout@v4
2828

2929
- name: "Update Generated Files"
3030
uses: martinthomson/i-d-template@v1

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
*~
88
.tags
99
/*-[0-9][0-9].xml
10+
/.*.mk
1011
/.gems/
1112
/.refcache
12-
/.targets.mk
1313
/.venv/
1414
/.vscode/
1515
/lib

Makefile

+7-3
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,12 @@ include $(LIBDIR)/main.mk
44
$(LIBDIR)/main.mk:
55
ifneq (,$(shell grep "path *= *$(LIBDIR)" .gitmodules 2>/dev/null))
66
git submodule sync
7-
git submodule update $(CLONE_ARGS) --init
7+
git submodule update --init
88
else
9-
git clone -q --depth 10 $(CLONE_ARGS) \
10-
-b main https://github.com/martinthomson/i-d-template $(LIBDIR)
9+
ifneq (,$(wildcard $(ID_TEMPLATE_HOME)))
10+
ln -s "$(ID_TEMPLATE_HOME)" $(LIBDIR)
11+
else
12+
git clone -q --depth 10 -b main \
13+
https://github.com/martinthomson/i-d-template $(LIBDIR)
14+
endif
1115
endif

0 commit comments

Comments
 (0)