1414 # Update the language picker in index.hbs to link new languages.
1515
1616jobs :
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 Gettext
30+ run : |
31+ sudo apt update
32+ sudo apt install gettext
33+
34+ - name : Install mdbook
35+ uses : ./.github/workflows/install-mdbook
36+
37+ - name : Upload pre-built-tools for the publish step
38+ uses : actions/upload-artifact@v4
39+ with :
40+ name : pre-built-tools
41+ path : $HOME/.cargo/bin/
42+
1743 create-translation :
1844 strategy :
1945 matrix :
4167 - " zh-CN"
4268 - " zh-TW"
4369 runs-on : ubuntu-latest
70+ needs : compile-build-tools
4471 steps :
4572 - name : Checkout
4673 uses : actions/checkout@v5
@@ -58,14 +85,11 @@ jobs:
5885 sudo apt update
5986 sudo apt install gettext
6087
61- - name : Install mdbook
62- uses : ./.github/workflows/install-mdbook
63-
64- - name : Upload i18n-report for the publish step
65- uses : actions/upload-artifact@v4
88+ - name : Download pre-built tools
89+ uses : actions/download-artifact@v4
6690 with :
67- name : tool-i18n-report
68- path : .cargo/bin/i18n-report
91+ name : pre-built-tools
92+ path : $HOME/ .cargo/bin/
6993
7094 - name : Build course in English
7195 if : matrix.language == 'en'
@@ -94,11 +118,11 @@ jobs:
94118 - name : Update Rust
95119 run : rustup update
96120
97- - name : Download i18n-report
121+ - name : Download pre-built tools
98122 uses : actions/download-artifact@v4
99123 with :
100- path : .cargo/bin
101- name : tool-i18n-report
124+ path : $HOME/ .cargo/bin/
125+ name : pre-built-tools
102126
103127 - name : Download all translations
104128 uses : actions/download-artifact@v4
0 commit comments