Skip to content

Commit 8638bd9

Browse files
authored
Merge pull request #78 from itowlson/update-spin-cli-reference
GitHub action to update Spin CLI reference
2 parents 03416ca + af093a8 commit 8638bd9

File tree

1 file changed

+56
-0
lines changed

1 file changed

+56
-0
lines changed
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Bump Spin
2+
3+
on:
4+
workflow_dispatch:
5+
# repository_dispatch:
6+
# types:
7+
# - spin-release
8+
9+
jobs:
10+
create-pr:
11+
name: Create PR with CLI reference bumped
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Download Spin
17+
uses: fermyon/actions/spin/setup@v1
18+
with:
19+
version: canary # for testing
20+
21+
- name: Create CLI reference front matter
22+
run: |
23+
cat >./content/v3/cli-reference.md << EOF
24+
title = "Command Line Reference"
25+
template = "main"
26+
date = "2025-01-01T00:00:01Z"
27+
[extra]
28+
url = "https://github.com/spinframework/spin-docs/blob/main/content/v3/cli-reference.md"
29+
30+
---
31+
EOF
32+
33+
- name: Generate reference doc
34+
run: ./spin maintenance generate-reference >>cli-reference.md
35+
36+
- name: Import GPG key
37+
uses: crazy-max/ghaction-import-gpg@v6
38+
with:
39+
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
40+
passphrase: ${{ secrets.PASSPHRASE }}
41+
git_user_signingkey: true
42+
git_commit_gpgsign: true
43+
44+
- name: Create pull request
45+
uses: peter-evans/create-pull-request@v7
46+
with:
47+
commit-message: "Update Spin CLI reference to latest"
48+
title: "Update Spin CLI reference to latest"
49+
body: "Update Spin CLI reference to latest"
50+
branch: bump-spin-cli-reference
51+
base: main
52+
delete-branch: true
53+
committer: spinframeworkbot <[email protected]>
54+
author: spinframeworkbot <[email protected]>
55+
signoff: true
56+
token: ${{ secrets.PAT }}

0 commit comments

Comments
 (0)