Skip to content

Commit

Permalink
feat: add release make target
Browse files Browse the repository at this point in the history
  • Loading branch information
atrakic committed Feb 27, 2023
1 parent 0d1992a commit ac308b4
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ sync reconcile: ## Sync
flux reconcile kustomization apps --with-source
flux get all --all-namespaces

clean: ## Clean up
clean: ## Clean up
echo ":: $(green)$@$(reset) :: "
kind delete cluster

Expand All @@ -78,8 +78,17 @@ test: ## Test demo app
release: ## Release (eg. V=0.0.1)
@[ "$(V)" ] \
&& read -p "Press enter to confirm and push tag v$(V) to origin, <Ctrl+C> to abort ..." \
&& git tag v$(V) -m "v$(V)" \
&& git push origin v$(V)
&& git tag v$(V) -m "chore: v$(V)" \
&& git push origin v$(V) -f \
&& git fetch --tags --force --all -p \
&& if [ ! -z "$(GITHUB_TOKEN)" ] ; then \
curl \
-H "Authorization: token $(GITHUB_TOKEN)" \
-X POST \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/$(GITHUB_USER)/$(shell basename $$PWD)/releases \
-d "{\"tag_name\":\"$(V)\",\"generate_release_notes\":true}"; \
fi;

help: ## Display this help menu
echo ":: $(green)$@$(reset) :: "
Expand Down

0 comments on commit ac308b4

Please sign in to comment.