-
Notifications
You must be signed in to change notification settings - Fork 27
41 lines (38 loc) · 1.16 KB
/
docs.yml
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
name: Generate Docs
on:
push:
branches:
- 'release-please--*'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
config:
runs-on: ubuntu-latest
steps:
- name: Extract branch name
shell: bash
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
id: extract_branch
- uses: actions/checkout@v4
with:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
ref: ${{ steps.extract_branch.outputs.branch }}
- uses: actions/setup-node@v4
with:
node-version: '18.x'
cache: 'yarn'
- run: yarn install --immutable
- run: yarn ci:generate-config-docs
- run: yarn prettier:fix
- name: Commit and push changes
run: |
if [[ `git status --porcelain` ]]; then
git config --local user.email "hello@tiltcamp.com"
git config --local user.name "TiltCamp"
git add CONFIG.md
git commit -m "docs: generate config docs"
git push
else
echo "No changes to commit"
fi