9292
9393 - name : ✂ Replace template in <head> of index.html
9494 if : github.event_name == 'push'
95- run : |
96- sed -i "s|<!-- INDEX_HTML_HEAD_REPLACEMENT -->|$INDEX_HTML_HEAD_REPLACEMENT|" frontend/index.html
95+ run : sed -i "s|<!-- INDEX_HTML_HEAD_REPLACEMENT -->|$INDEX_HTML_HEAD_REPLACEMENT|" frontend/index.html
9796
9897 - name : 🌐 Build Graphite web code
9998 env :
@@ -165,8 +164,7 @@ jobs:
165164
166165 - name : ✂ Strip analytics script from built output for clean artifact
167166 if : github.event_name == 'push'
168- run : |
169- sed -i "s|$INDEX_HTML_HEAD_REPLACEMENT||" frontend/dist/index.html
167+ run : sed -i "s|$INDEX_HTML_HEAD_REPLACEMENT||" frontend/dist/index.html
170168
171169 - name : 📦 Upload web bundle artifact
172170 uses : actions/upload-artifact@v6
@@ -177,49 +175,38 @@ jobs:
177175 - name : 📃 Generate code documentation info for website
178176 if : github.event_name == 'push'
179177 run : |
180- cd tools/editor-message-tree
181- cargo run
182- cd ../..
183- mkdir -p artifacts-generated
184- mv website/generated/hierarchical_message_system_tree.txt artifacts-generated/hierarchical_message_system_tree.txt
178+ mkdir -p website/generated-new
179+ cargo run -p crate-hierarchy-viz -- website/generated-new/crate_hierarchy.dot
180+ cargo run -p editor-message-tree -- website/generated-new/hierarchical_message_system_tree.txt
185181
186182 - name : 💿 Obtain cache of auto-generated code docs artifacts, to check if they've changed
187183 if : github.event_name == 'push'
188184 id : cache-website-code-docs
189185 uses : actions/cache/restore@v5
190186 with :
191- path : artifacts
187+ path : website/generated
192188 key : website-code-docs
193189
194190 - name : 🔍 Check if auto-generated code docs artifacts changed
195191 if : github.event_name == 'push'
196192 id : website-code-docs-changed
197193 run : |
198- if ! diff --brief --recursive artifacts-generated artifacts; then
199- echo "Auto-generated code docs artifacts have changed."
200- rm -rf artifacts
201- mv artifacts-generated artifacts
202- echo "changed=true" >> $GITHUB_OUTPUT
203- else
204- echo "Auto-generated code docs artifacts have not changed."
205- rm -rf artifacts
206- rm -rf artifacts-generated
207- fi
194+ diff --brief --recursive website/generated-new website/generated || echo "changed=true" >> $GITHUB_OUTPUT
195+ rm -rf website/generated
196+ mv website/generated-new website/generated
208197
209198 - name : 💾 Save cache of auto-generated code docs artifacts
210199 if : github.event_name == 'push' && steps.website-code-docs-changed.outputs.changed == 'true'
211200 uses : actions/cache/save@v5
212201 with :
213- path : artifacts
202+ path : website/generated
214203 key : ${{ steps.cache-website-code-docs.outputs.cache-primary-key }}
215204
216205 - name : ♻️ Trigger website rebuild if the auto-generated code docs artifacts have changed
217206 if : github.event_name == 'push' && steps.website-code-docs-changed.outputs.changed == 'true'
218207 env :
219208 GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
220- run : |
221- rm -rf artifacts
222- gh workflow run website.yml --ref master
209+ run : gh workflow run website.yml --ref master
223210
224211 windows :
225212 if : github.event_name == 'push' || inputs.windows
0 commit comments