Skip to content

Commit 1f4e98a

Browse files
authored
Merge branch 'main' into record-wrapping
2 parents 684e1ed + 1fd3c72 commit 1f4e98a

67 files changed

Lines changed: 8709 additions & 2062 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.codacy.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
exclude_paths:
3+
- "site/package-lock.json"
4+
- "site/node_modules/**"
5+
- "site/dist/**"

.github/workflows/add-hip-number.yml

Lines changed: 28 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,20 @@ defaults:
99
shell: bash
1010

1111
permissions:
12-
contents: write
13-
issues: read
14-
pull-requests: write
15-
checks: write
12+
contents: read
1613

1714
jobs:
1815
assign-hip-number:
1916
runs-on: hiero-improvement-proposals-linux-medium
2017
continue-on-error: true # Silently fail - don't show red X on PRs
2118
steps:
2219
- name: Harden Runner
23-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
20+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
2421
with:
2522
egress-policy: audit
2623

2724
- name: Checkout Code
28-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
25+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2926
with:
3027
token: ${{ secrets.GH_ACCESS_TOKEN }}
3128
fetch-depth: 0
@@ -52,7 +49,7 @@ jobs:
5249
5350
# Directory path to check for HIP files
5451
HIP_DIRECTORY='HIP'
55-
HIP_FILES=$(echo "$MODIFIED_FILES" | grep "^$HIP_DIRECTORY/.*\.md")
52+
HIP_FILES=$(echo "$MODIFIED_FILES" | grep "^$HIP_DIRECTORY/.*\.md" || true)
5653
echo "Filtered HIP files: $HIP_FILES"
5754
echo "::set-output name=hip-files::$HIP_FILES"
5855
@@ -82,11 +79,12 @@ jobs:
8279
8380
- name: Assign HIP Number
8481
if: steps.check-new.outputs.new-hip == 'true'
82+
env:
83+
PR_NUMBER: ${{ github.event.pull_request.number }}
84+
HIP_FILES: ${{ steps.check-new.outputs.hip-files }}
8585
run: |
86-
# Extract the current PR number
87-
PR_NUMBER=${{ github.event.pull_request.number }}
8886
HIP_HEADER="hip: $PR_NUMBER"
89-
HIP_FILE=$(echo "${{ steps.check-new.outputs.hip-files }}" | head -n 1)
87+
HIP_FILE=$(echo "$HIP_FILES" | head -n 1)
9088
9189
echo "Assigning HIP number to file: $HIP_FILE"
9290
@@ -99,26 +97,37 @@ jobs:
9997
10098
- name: Rename HIP File
10199
if: steps.check-new.outputs.new-hip == 'true'
100+
env:
101+
PR_NUMBER: ${{ github.event.pull_request.number }}
102+
HIP_FILES: ${{ steps.check-new.outputs.hip-files }}
102103
run: |
103-
# Extract PR number
104-
PR_NUMBER=${{ github.event.pull_request.number }}
105-
HIP_FILE=$(echo "${{ steps.check-new.outputs.hip-files }}" | head -n 1)
104+
HIP_FILE=$(echo "$HIP_FILES" | head -n 1)
106105
107-
if [ -n "$HIP_FILE" ]; then
108-
NEW_HIP_FILE="HIP/hip-$PR_NUMBER.md"
109-
mv "$HIP_FILE" "$NEW_HIP_FILE"
110-
else
106+
if [ -z "$HIP_FILE" ]; then
111107
echo "No HIP file found to rename. Skipping rename."
112108
exit 0
113109
fi
114110
111+
NEW_HIP_FILE="HIP/hip-$PR_NUMBER.md"
112+
113+
# Skip the rename when the file is already correctly named; otherwise
114+
# `mv <same> <same>` exits non-zero and aborts the remaining steps.
115+
if [ "$HIP_FILE" = "$NEW_HIP_FILE" ]; then
116+
echo "HIP file already has expected name ($NEW_HIP_FILE). Skipping rename."
117+
exit 0
118+
fi
119+
120+
mv "$HIP_FILE" "$NEW_HIP_FILE"
121+
115122
- name: Commit Changes
116123
if: steps.check-new.outputs.new-hip == 'true'
124+
env:
125+
PR_NUMBER: ${{ github.event.pull_request.number }}
126+
HEAD_REF: ${{ github.head_ref }}
117127
run: |
118128
git config --global user.name 'GitHub Action'
119129
git config --global user.email 'action@github.com'
120130
121-
PR_NUMBER=${{ github.event.pull_request.number }}
122131
git add HIP/
123132
124133
# Check if there are changes to commit
@@ -132,7 +141,7 @@ jobs:
132141
exit 0
133142
}
134143
135-
git push origin HEAD:${{ github.head_ref }} || {
144+
git push origin "HEAD:$HEAD_REF" || {
136145
echo "Push failed. This is expected for PRs from forks without write access."
137146
echo "The PR author will need to manually update their branch."
138147
exit 0

.github/workflows/deploy-site.yml

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
name: Deploy Site
2+
3+
on:
4+
push:
5+
branches: [main]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
pull-requests: read
13+
discussions: read
14+
15+
concurrency:
16+
group: "pages"
17+
cancel-in-progress: false
18+
19+
jobs:
20+
build:
21+
runs-on: hiero-improvement-proposals-linux-medium
22+
steps:
23+
- name: Harden the runner (Audit all outbound calls)
24+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
25+
with:
26+
egress-policy: audit
27+
28+
- name: Checkout
29+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
30+
31+
- name: Setup Node.js
32+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
33+
with:
34+
node-version: "20"
35+
36+
- name: Install dependencies
37+
working-directory: site
38+
run: npm ci
39+
40+
- name: Setup Pages
41+
id: pages
42+
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
43+
44+
- name: Build data
45+
working-directory: site
46+
run: npm run build:data
47+
env:
48+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
49+
50+
- name: Build site
51+
working-directory: site
52+
run: npm run build
53+
env:
54+
VITE_BASE: ${{ steps.pages.outputs.base_path }}/
55+
56+
- name: Upload artifact
57+
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
58+
with:
59+
path: site/dist
60+
61+
deploy:
62+
environment:
63+
name: github-pages
64+
url: ${{ steps.deployment.outputs.page_url }}
65+
runs-on: hiero-improvement-proposals-linux-medium
66+
needs: build
67+
steps:
68+
- name: Harden the runner (Audit all outbound calls)
69+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
70+
with:
71+
egress-policy: audit
72+
73+
- name: Deploy to GitHub Pages
74+
id: deployment
75+
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0

.github/workflows/notifications.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: Dispatch Status Change Notifications (discord and email)
22
permissions:
3-
contents: read
4-
actions: write
3+
contents: read
54
on:
65
push:
76
branches:
@@ -13,14 +12,17 @@ defaults:
1312
jobs:
1413
DispatchNotifications:
1514
runs-on: hiero-improvement-proposals-linux-medium
15+
permissions:
16+
contents: read
17+
actions: write
1618
steps:
1719
- name: Harden Runner
18-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
20+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
1921
with:
2022
egress-policy: audit
2123

2224
- name: Check out repository code
23-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
25+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2426
with:
2527
fetch-depth: 0
2628

.github/workflows/schedule-last-call-date-end.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
name: Schedule Status Update Based on Last Call Time
22

33
permissions:
4-
pull-requests: write
5-
contents: write
6-
packages: write
4+
contents: read
75

86
defaults:
97
run:
@@ -19,15 +17,18 @@ jobs:
1917
check-merged-file:
2018
if: github.event.pull_request.merged == true
2119
runs-on: hiero-improvement-proposals-linux-medium
20+
permissions:
21+
contents: write
22+
pull-requests: write
2223

2324
steps:
2425
- name: Harden Runner
25-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
26+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
2627
with:
2728
egress-policy: audit
2829

2930
- name: Check out the code
30-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
31+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3132

3233
- name: Import GPG Key
3334
id: gpg_importer

.github/workflows/send-discord-message.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ on:
1313

1414
permissions:
1515
contents: read
16-
actions: write
1716

1817
defaults:
1918
run:
@@ -24,12 +23,12 @@ jobs:
2423
runs-on: hiero-improvement-proposals-linux-medium
2524
steps:
2625
- name: Harden Runner
27-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
26+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
2827
with:
2928
egress-policy: audit
3029

3130
- name: Checkout repository
32-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
31+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3332

3433
- name: Extract HIP abstract
3534
id: extract_abstract
@@ -72,7 +71,7 @@ jobs:
7271
- name: Discord notification
7372
env:
7473
DISCORD_WEBHOOK: ${{ secrets.DISCORD }}
75-
uses: step-security/action-discord@e31fd4e664027caad89e85cc4e9166e193dd6d2d # v0.1.5
74+
uses: step-security/action-discord@e90293dc70f4cb5ad8e6629672f306b2742d8b7f # v0.1.6
7675
with:
7776
args: |
7877
# ${{ steps.extract_abstract.outputs.filename_no_ext }} moved into ${{ github.event.inputs.status }} status

.github/workflows/send-email.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ jobs:
2222
runs-on: hiero-improvement-proposals-linux-medium
2323
steps:
2424
- name: Harden Runner
25-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
25+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
2626
with:
2727
egress-policy: audit
2828

2929
- name: Send mail
30-
uses: step-security/action-send-mail@7238bab69680f644f9eab409cec92179d1d2f0ce # v6.0.1
30+
uses: step-security/action-send-mail@6427d1c42f41e0c0d4df587e2e1e583fd81b048d # v16.0.0
3131
with:
3232
server_address: smtp.gmail.com
3333
server_port: 465

.github/workflows/stale-hip-management.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,12 @@ jobs:
2929

3030
steps:
3131
- name: Harden Runner
32-
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2
32+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
3333
with:
3434
egress-policy: audit
3535

3636
- name: Check out the code
37-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
37+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3838

3939
- name: Process Stale PRs
4040
env:

0 commit comments

Comments
 (0)