-
-
Notifications
You must be signed in to change notification settings - Fork 4
55 lines (52 loc) · 1.57 KB
/
ci.yml
File metadata and controls
55 lines (52 loc) · 1.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: CI
permissions: {}
on:
pull_request:
push:
branches:
- alpha
- beta
- main
- renovate/**
jobs:
ci-optimization:
name: CI optimization
uses: dargmuesli/github-actions/.github/workflows/ci-optimization.yml@661e39fe1c9e484d94c6a5a9d4c9946d57c41771 # 5.1.0
permissions:
pull-requests: read
build:
needs: ci-optimization
if: needs.ci-optimization.outputs.continue == 'true'
name: Update generated docs
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref || github.ref_name }}
- name: Regenerate docs
run: |
go install github.com/dargstack/dargstack/v4/cmd/dargstack@latest
export PATH="$(go env GOPATH)/bin:$PATH"
dargstack document
- name: Commit and push updated docs
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add artifacts/docs/
if git diff --staged --quiet; then
echo "Docs are already up to date"
else
git commit -m "chore: update generated docs"
git push
fi
release-semantic:
needs: build
name: Semantic Release
uses: dargmuesli/github-actions/.github/workflows/release-semantic.yml@661e39fe1c9e484d94c6a5a9d4c9946d57c41771 # 5.1.0
permissions:
contents: write
id-token: write
secrets:
PERSONAL_ACCESS_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}