|
14 | 14 | # Update the language picker in index.hbs to link new languages.
|
15 | 15 |
|
16 | 16 | jobs:
|
17 |
| - compile-build-tools: |
18 |
| - runs-on: ubuntu-latest |
19 |
| - steps: |
20 |
| - - name: Checkout |
21 |
| - uses: actions/checkout@v4 |
22 |
| - |
23 |
| - - name: Update Rust |
24 |
| - run: rustup update |
25 |
| - |
26 |
| - - name: Setup Rust cache |
27 |
| - uses: ./.github/workflows/setup-rust-cache |
28 |
| - |
29 |
| - - name: Install build tools |
30 |
| - uses: taiki-e/install-action@v2 |
31 |
| - with: |
32 |
| - # testing without version first but should be |
33 |
| - |
34 |
| - |
35 |
| - |
36 |
| - |
37 |
| - |
38 |
| - |
39 |
| - tool: mdbook,mdbook-svgbob,mdbook-pandoc,mdbook-i18n-helpers,i18n-report,mdbook-linkcheck2 |
40 |
| - |
41 |
| - - name: Install mdbook |
42 |
| - run: cargo xtask install-tools |
43 |
| - |
44 |
| - - name: Upload pre-built-tools for the next tasks |
45 |
| - uses: actions/upload-artifact@v4 |
46 |
| - with: |
47 |
| - name: pre-built-tools |
48 |
| - path: /home/runner/.cargo/bin/ |
49 |
| - |
50 | 17 | create-translation:
|
51 | 18 | strategy:
|
52 | 19 | matrix:
|
|
74 | 41 | - "zh-CN"
|
75 | 42 | - "zh-TW"
|
76 | 43 | runs-on: ubuntu-latest
|
77 |
| - needs: compile-build-tools |
78 | 44 | steps:
|
79 | 45 | - name: Checkout
|
80 | 46 | uses: actions/checkout@v5
|
|
92 | 58 | with:
|
93 | 59 | packages: gettext
|
94 | 60 |
|
95 |
| - - name: Download pre-built tools |
96 |
| - uses: actions/download-artifact@v4 |
97 |
| - with: |
98 |
| - name: pre-built-tools |
99 |
| - path: /home/runner/.cargo/bin/ |
100 |
| - |
101 |
| - - name: Make all downloaded tools executable |
102 |
| - run: chmod +x /home/runner/.cargo/bin/* |
103 |
| - |
104 |
| - - name: Install dependencies for mdbook-pandoc |
105 |
| - run: | |
106 |
| - sudo apt-get update |
107 |
| - sudo apt-get install -y texlive texlive-luatex texlive-lang-cjk texlive-lang-arabic librsvg2-bin fonts-noto |
108 |
| - curl -LsSf https://github.com/jgm/pandoc/releases/download/3.7.0.1/pandoc-3.7.0.1-linux-amd64.tar.gz | tar zxf - |
109 |
| - echo "$PWD/pandoc-3.7.0.1/bin" >> $GITHUB_PATH |
110 |
| - shell: bash |
| 61 | + - name: Install mdbook |
| 62 | + uses: ./.github/workflows/install-mdbook |
111 | 63 |
|
112 | 64 | - name: Build course in English
|
113 | 65 | if: matrix.language == 'en'
|
@@ -136,20 +88,14 @@ jobs:
|
136 | 88 | - name: Update Rust
|
137 | 89 | run: rustup update
|
138 | 90 |
|
139 |
| - - name: Download pre-built tools |
140 |
| - uses: actions/download-artifact@v4 |
141 |
| - with: |
142 |
| - path: /home/runner/.cargo/bin/ |
143 |
| - name: pre-built-tools |
144 |
| - |
145 |
| - - name: Make all downloaded tools executable |
146 |
| - run: chmod +x /home/runner/.cargo/bin/* |
147 |
| - |
148 | 91 | - name: Install Gettext
|
149 | 92 | run: |
|
150 | 93 | sudo apt update
|
151 | 94 | sudo apt install gettext
|
152 | 95 |
|
| 96 | + - name: Install mdbook |
| 97 | + uses: ./.github/workflows/install-mdbook |
| 98 | + |
153 | 99 | - name: Download all translations
|
154 | 100 | uses: actions/download-artifact@v4
|
155 | 101 | with:
|
|
0 commit comments