mirror of
https://github.com/MLSysBook/TinyTorch.git
synced 2026-04-28 23:57:32 -05:00
Fix GitHub workflow to properly activate virtual environment
- Combine venv setup and tito execution in same step - Add pytest installation for tito environment validation - Add explanatory comments about GitHub Actions shell behavior - Remove environment skipping hack in favor of proper setup - Workflow now uses tito CLI consistently for book generation
This commit is contained in:
10
.github/workflows/deploy-book.yml
vendored
10
.github/workflows/deploy-book.yml
vendored
@@ -1,6 +1,7 @@
|
||||
name: Deploy TinyTorch Jupyter Book (Streamlined)
|
||||
name: Deploy TinyTorch Jupyter Book (Streamlined with tito)
|
||||
|
||||
# Trigger the workflow on push to main branch (publishing) or manual dispatch
|
||||
# This workflow uses tito CLI for consistent book generation and building
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
@@ -48,10 +49,17 @@ jobs:
|
||||
pip install --upgrade pip
|
||||
pip install jupyter-book jupytext
|
||||
pip install -r book/requirements.txt
|
||||
pip install -r requirements.txt # Install main project dependencies
|
||||
pip install -e . # Install tito CLI
|
||||
|
||||
- name: Generate content and build book
|
||||
run: |
|
||||
# Set up virtual environment and run tito in same step
|
||||
# Note: Each GitHub Actions step runs in a separate shell,
|
||||
# so we need to activate the venv in the same step as tito
|
||||
python -m venv .venv
|
||||
source .venv/bin/activate
|
||||
pip install pytest # Install missing dependency for tito environment checks
|
||||
# Use tito to generate content and build book
|
||||
tito book build
|
||||
|
||||
|
||||
Reference in New Issue
Block a user