.PHONY: sync-from-github sync-to-github chat router

# Pull latest changes from the GitHub mirror and push them to Gitea
sync-from-github:
	git pull github main
	git push origin main

# Push local changes to the GitHub mirror
sync-to-github:
	git push github main

# Start the chat UI locally (uses variables from .env if present)
chat:
	@set -a; [ -f .env ] && . .env || true; set +a; \
	cd chat-ui && npm install && npm run build && npm start

# Start the WhatsApp router locally (uses variables from .env if present)
router:
	@set -a; [ -f .env ] && . .env || true; set +a; \
	cd whatsapp-router && npm install && npm run build && npm start
