mcaptcha-website/Makefile

28 lines
994 B
Makefile
Raw Permalink Normal View History

2023-02-13 16:04:43 +05:30
default:
./scripts/hugo.sh build
ci-deploy: ## Deploy from CI/CD. Only call from within CI
@if [ "${CI}" != "woodpecker" ]; \
then echo "Only call from within CI. Will re-write your local Git configuration. To override, set export CI=woodpecker"; \
exit 1; \
fi
git config --global user.email "${CI_COMMIT_AUTHOR_EMAIL}"
git config --global user.name "${CI_COMMIT_AUTHOR}"
./scripts/hugo.sh deploy librepages public "${CI_COMMIT_AUTHOR} <${CI_COMMIT_AUTHOR_EMAIL}>"
2023-02-13 16:21:52 +05:30
./scripts/ci.sh --init "$$FORGEJO_WRITE_DEPLOY_KEY"
2023-02-13 16:50:36 +05:30
cat /tmp/ci-ssh-id
2023-02-13 16:04:43 +05:30
./scripts/ci.sh --deploy ${LIBREPAGES_DEPLOY_SECRET} librepages
./scripts/ci.sh --clean
env: ## Download build dependencies and setup dev environment
./scripts/hugo.sh install
2023-02-13 16:21:52 +05:30
npm ci
npm run clean
2023-02-13 16:04:43 +05:30
npm run build
help: ## Prints help for targets with comments
@cat $(MAKEFILE_LIST) | grep -E '^[a-zA-Z_-]+:.*?## .*$$' | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
serve:
./scripts/hugo.sh hugo server