notes.velouria.dev/Makefile

21 lines
688 B
Makefile

.DEFAULT_GOAL := help
help:
@echo "Available targets:"
@echo " publish Restart Docker Compose (or run 'npx quartz build --serve' with local=True)."
@echo " preview Run 'npx quartz build --serve' with specific directories."
# Default directories for the publish target
SOURCE_DIR = $(HOME)/Documents/obsidian/gal/Gal
DEST_DIR = $(HOME)/Workspace/heygal.space/content
# Target-specific variables for the publish target
publish:
@./scripts/publish.sh "$(SOURCE_DIR)" "$(DEST_DIR)"
@if [ "$(local)" = "True" ]; then \
echo "Running npx quartz build --serve"; \
npx quartz build --serve; \
else \
echo "Restarting Docker Compose"; \
docker compose restart; \
fi