Skip to content

Commit 26092ac

Browse files
committed
Fix the workflows
1 parent 01fa614 commit 26092ac

File tree

2 files changed

+38
-20
lines changed

2 files changed

+38
-20
lines changed

.github/workflows/archive.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,28 +5,38 @@ on:
55
- cron: '0 0 * * 0,2,4'
66
repository_dispatch:
77
types: [archive]
8+
workflow_dispatch:
9+
inputs:
10+
archive_full:
11+
description: 'Recreate the archive from scratch'
12+
default: false
13+
type: boolean
814

915
jobs:
1016
build:
1117
name: "Archive Issues and Pull Requests"
1218
runs-on: ubuntu-latest
1319
steps:
1420
- name: "Checkout"
15-
uses: actions/checkout@v2
21+
uses: actions/checkout@v4
22+
23+
# Note: No caching for this build!
1624

1725
- name: "Update Archive"
1826
uses: martinthomson/i-d-template@v1
27+
env:
28+
ARCHIVE_FULL: ${{ inputs.archive_full }}
1929
with:
2030
make: archive
21-
token: ${{ secrets.GITHUB_TOKEN }}
31+
token: ${{ github.token }}
2232

2333
- name: "Update GitHub Pages"
2434
uses: martinthomson/i-d-template@v1
2535
with:
2636
make: gh-archive
27-
token: ${{ secrets.GITHUB_TOKEN }}
37+
token: ${{ github.token }}
2838

2939
- name: "Save Archive"
30-
uses: actions/upload-artifact@v2
40+
uses: actions/upload-artifact@v4
3141
with:
3242
path: archive.json

.github/workflows/publish.yml

Lines changed: 24 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,46 +4,54 @@ 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@v2
20+
uses: actions/checkout@v4
1521

1622
# See https://github.com/actions/checkout/issues/290
1723
- name: "Get Tag Annotations"
1824
run: git fetch -f origin ${{ github.ref }}:${{ github.ref }}
1925

20-
- name: "Cache Setup"
21-
id: cache-setup
22-
run: |
23-
mkdir -p "$HOME"/.cache/xml2rfc
24-
echo "::set-output name=path::$HOME/.cache/xml2rfc"
25-
date -u "+::set-output name=date::%FT%T"
26+
- name: "Setup"
27+
id: setup
28+
run: date -u "+date=%FT%T" >>"$GITHUB_OUTPUT"
2629

27-
- name: "Cache References"
28-
uses: actions/cache@v2
30+
- name: "Caching"
31+
uses: actions/cache@v4
2932
with:
3033
path: |
31-
${{ steps.cache-setup.outputs.path }}
34+
.refcache
35+
.venv
36+
.gems
37+
node_modules
3238
.targets.mk
33-
key: refcache-${{ steps.date.outputs.date }}
34-
restore-keys: |
35-
refcache-${{ steps.date.outputs.date }}
36-
refcache-
39+
key: i-d-${{ steps.setup.outputs.date }}
40+
restore-keys: i-d-
3741

3842
- name: "Build Drafts"
3943
uses: martinthomson/i-d-template@v1
44+
with:
45+
token: ${{ github.token }}
4046

4147
- name: "Upload to Datatracker"
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@v2
55+
uses: actions/upload-artifact@v4
4856
with:
49-
path: "draft-*-[0-9][0-9].xml"
57+
path: "versioned/draft-*-[0-9][0-9].*"

0 commit comments

Comments
 (0)