Repository navigation
60 lines (57 loc) · 2.01 KB
/
Copy pathci.yml
File metadata and controls
60 lines (57 loc) · 2.01 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
56
57
58
59
60
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@69154c1ca2c2bc78ee9fa87f3ac206243aaf85ff # 5.9.10
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@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
ref: ${{ github.head_ref || github.ref_name }}
- name: Install dargstack
run: |
ARCHIVE="dargstack_$(uname -s | tr '[:upper:]' '[:lower:]')_$(uname -m | sed -e 's/x86_64/amd64/' -e 's/aarch64/arm64/').tar.gz"
curl -sfL -o "$ARCHIVE" "https://github.com/dargstack/dargstack/releases/latest/download/$ARCHIVE"
curl -sfL https://github.com/dargstack/dargstack/releases/latest/download/checksums.txt | sha256sum -c - --ignore-missing
tar xzf "$ARCHIVE" && rm "$ARCHIVE"
mv dargstack /usr/local/bin/
- name: Regenerate docs
run: dargstack document
- name: Commit and push updated docs
if: github.event_name == 'push'
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@69154c1ca2c2bc78ee9fa87f3ac206243aaf85ff # 5.9.10
permissions:
contents: write
id-token: write
secrets:
PERSONAL_ACCESS_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}