CS Pathway Game - Build Integration
Guide for integrating CS Pathway Game into Makefile and CI/CD workflows
Adding CS Pathway Game to Build System
This project now uses the shared auto-registration build system. You do not need a Makefile fragment or project-specific targets in the root Makefile.
Current Architecture
The root Makefile provides generic targets that run for every registered project:
build-registered-projectsbuild-registered-docswatch-registered-projectsclean-registered-projects
Projects are discovered from _projects/.makeprojects and executed with:
make -C _projects/<project-name> <target>
Each project Makefile must expose these generic targets:
buildcleandocsdocs-cleanwatch
Step 1: Register Project
Add one line to _projects/.makeprojects:
cs-pathway-game
No include lines are required in the root Makefile.
Step 2: Use the Standard Project Makefile Template
Project Makefiles are template-friendly and infer project name from folder name.
In most cases, the only value you change per project is DATE_OF_CREATION.
# _projects/<project-name>/Makefile
DATE_OF_CREATION = 2026-04-02
PROJECT_SRC = $(CURDIR)
PROJECT_NAME = $(notdir $(PROJECT_SRC))
NOTEBOOK_FILENAME = $(DATE_OF_CREATION)-$(PROJECT_NAME).ipynb
WORKSPACE_ROOT = ../..
JS_DEST = $(WORKSPACE_ROOT)/assets/js/projects/$(PROJECT_NAME)
IMAGES_DEST = $(WORKSPACE_ROOT)/images/projects/$(PROJECT_NAME)
NOTEBOOK_DEST = $(WORKSPACE_ROOT)/_notebooks/projects/$(PROJECT_NAME)
DOCS_DEST = $(WORKSPACE_ROOT)/_posts/projects/$(PROJECT_NAME)
Step 3: Local Build + Dev Behavior
Local top-level commands already include registered projects:
make refreshruns rootmakeflow, which usesserve-currentserve-currentincludesbuild-registered-projectsandbuild-registered-docsmake devstartswatch-registered-projects
No project-specific watcher wiring is needed in the root Makefile.
Step 4: CI/CD Behavior
GitHub Actions should call generic registered targets:
- name: Build registered projects
run: |
make build-registered-projects
make build-registered-docs
This is now the canonical CI integration point (not make <project>-build).
Step 5: Verification
Validate one project directly:
make -C _projects/cs-pathway-game build
make -C _projects/cs-pathway-game docs
Validate all registered projects:
make build-registered-projects
make build-registered-docs
Expected outputs:
- Notebook:
_notebooks/projects/cs-pathway-game/<date>-cs-pathway-game.ipynb - Assets:
assets/js/projects/cs-pathway-game/andimages/projects/cs-pathway-game/ - Docs:
_posts/projects/cs-pathway-game/<date>-cs-pathway-game-*.md
Troubleshooting
fswatch Not Found
If you see: ⚠️ fswatch not installed
# macOS:
brew install fswatch
# Linux:
sudo apt-get install fswatch # Debian/Ubuntu
sudo yum install fswatch # RedHat/CentOS
Auto-copy Not Working
-
Check that the project watcher is running via the registered watcher target:
ps aux | grep "make -C _projects" -
Manually trigger copy to test:
make -C _projects/cs-pathway-game build -
Check file permissions:
ls -la _projects/cs-pathway-game/
Jekyll Not Regenerating After Copy
-
Check Jekyll is watching:
tail -f /tmp/jekyll4500.log -
Look for file change events in log when you save
-
Restart dev server:
make stop make dev
Summary
After integration, your workflow becomes:
- Register once: add project name to
_projects/.makeprojects. - Template reuse: keep generic targets in project Makefile and update
DATE_OF_CREATION. - Use shared commands: root Makefile and CI run all registered projects automatically.
No manual build steps needed during development!