-
Notifications
You must be signed in to change notification settings - Fork 187
39 lines (32 loc) · 883 Bytes
/
book.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
name: Gitbook Generation
on:
workflow_dispatch:
push:
branches:
- main
pull_request_target:
branches:
- main
jobs:
gitbook-generation:
runs-on: ubuntu-latest
strategy:
matrix:
language: [en, ja, zh, pt-br, gl]
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: '2.6'
working-directory: 'book/scripts/'
bundler-cache: true
- name: Generate ToC
run: |
cd book/scripts/
ruby generate_toc.rb ${{ matrix.language }}
echo "Generated book for: ${{ matrix.language }}" >> $GITHUB_STEP_SUMMARY
- name: Commit updated toc.md for the book
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Writing updated toc.md for the ${{ matrix.language }} book
branch: ${{ github.head_ref }}