|
| 1 | +# Deployment Guide |
| 2 | + |
| 3 | +## GitHub Pages Deployment |
| 4 | + |
| 5 | +This presentation site is automatically deployed to GitHub Pages via GitHub Actions. |
| 6 | + |
| 7 | +### Why We Use `lib/` Instead of `node_modules/` |
| 8 | + |
| 9 | +GitHub Pages has restrictions on serving certain directories. The `node_modules` directory, even when included in Jekyll config, may not be reliably served. To fix this: |
| 10 | + |
| 11 | +1. **reveal.js files are copied to `lib/reveal.js/`** during build |
| 12 | +2. **All presentations reference `../../lib/reveal.js/`** instead of `../../node_modules/reveal.js/` |
| 13 | +3. **The build process automatically sets up the `lib` directory** |
| 14 | + |
| 15 | +### Build Process |
| 16 | + |
| 17 | +The GitHub Actions workflow: |
| 18 | + |
| 19 | +1. Installs dependencies with `npm ci` |
| 20 | +2. Runs `npm run build` which copies reveal.js files to `lib/` |
| 21 | +3. Deploys the site to GitHub Pages |
| 22 | + |
| 23 | +### Local Development |
| 24 | + |
| 25 | +For local development: |
| 26 | + |
| 27 | +```bash |
| 28 | +# Install dependencies and set up lib directory |
| 29 | +npm install |
| 30 | + |
| 31 | +# Start local server |
| 32 | +npm run serve |
| 33 | + |
| 34 | +# Or use the task runner |
| 35 | +task install |
| 36 | +task serve |
| 37 | +``` |
| 38 | + |
| 39 | +### Creating New Presentations |
| 40 | + |
| 41 | +Use the task runner to create presentations: |
| 42 | + |
| 43 | +```bash |
| 44 | +task new -- my-presentation-name |
| 45 | +``` |
| 46 | + |
| 47 | +This automatically creates presentations that use the correct `lib/reveal.js/` paths. |
| 48 | + |
| 49 | +### If You Get 404 Errors |
| 50 | + |
| 51 | +If presentations show 404 errors on GitHub Pages: |
| 52 | + |
| 53 | +1. Check that the `lib/` directory exists and contains reveal.js files |
| 54 | +2. Ensure presentations reference `../../lib/reveal.js/` paths |
| 55 | +3. Verify the GitHub Actions build completed successfully |
| 56 | +4. Check that `_config.yml` includes the `lib` directory |
| 57 | + |
| 58 | +### Manual Build |
| 59 | + |
| 60 | +To manually rebuild the lib directory: |
| 61 | + |
| 62 | +```bash |
| 63 | +npm run build |
| 64 | +# or |
| 65 | +task setup-lib |
| 66 | +``` |
| 67 | + |
0 commit comments