Improves artifact verification and output naming

Updates the book publishing workflow to conditionally verify downloaded artifacts based on the `deploy_target` input, preventing failures during partial deployments.

Explicitly sets the output filenames for EPUB and PDF builds in Quarto configurations, ensuring consistent naming for generated book artifacts.
This commit is contained in:
Vijay Janapa Reddi
2026-03-02 17:51:04 -05:00
parent 354cb2000f
commit 8129e4b31f
5 changed files with 11 additions and 2 deletions

View File

@@ -913,8 +913,13 @@ jobs:
- name: 📋 Verify Downloaded Artifacts
run: |
echo "📦 Verifying downloaded artifacts..."
if [ ! -d "html-vol1-temp" ] || [ ! -d "html-vol2-temp" ]; then
echo "❌ Required volume HTML artifacts were not downloaded."
DEPLOY_TARGET="${{ github.event.inputs.deploy_target }}"
if [[ "$DEPLOY_TARGET" == "vol1" || "$DEPLOY_TARGET" == "all" ]] && [ ! -d "html-vol1-temp" ]; then
echo "❌ Required Volume I HTML artifact was not downloaded."
exit 1
fi
if [[ "$DEPLOY_TARGET" == "vol2" || "$DEPLOY_TARGET" == "all" ]] && [ ! -d "html-vol2-temp" ]; then
echo "❌ Required Volume II HTML artifact was not downloaded."
exit 1
fi

View File

@@ -11,6 +11,7 @@
project:
type: book
output-dir: _build/epub-vol1
output-file: Machine-Learning-Systems.epub
execute-dir: project
post-render:
- scripts/clean_svgs.py

View File

@@ -11,6 +11,7 @@
project:
type: book
output-dir: _build/epub-vol2
output-file: Machine-Learning-Systems.epub
execute-dir: project
post-render:
- scripts/clean_svgs.py

View File

@@ -14,6 +14,7 @@
project:
output-dir: _build/pdf-vol1
output-file: Machine-Learning-Systems.pdf
book:
favicon: assets/images/icons/favicon.png

View File

@@ -10,6 +10,7 @@
project:
output-dir: _build/pdf-vol2
output-file: Machine-Learning-Systems.pdf
book:
favicon: assets/images/icons/favicon.png