chore: add release preparation tasks with changelog generation

This commit is contained in:
wpetit 2022-08-01 10:36:00 +02:00
parent 252eb65b88
commit e6d7ed5904
4 changed files with 42 additions and 13 deletions

View File

@ -5,18 +5,18 @@ info:
repository_url: https://github.com/Bornholm/formidable repository_url: https://github.com/Bornholm/formidable
options: options:
commits: commits:
# filters: filters:
# Type: Type:
# - feat - feat
# - fix - fix
# - perf - perf
# - refactor - refactor
commit_groups: commit_groups:
# title_maps: title_maps:
# feat: Features feat: Features
# fix: Bug Fixes fix: Bug Fixes
# perf: Performance Improvements perf: Performance Improvements
# refactor: Code Refactoring refactor: Code Refactoring
header: header:
pattern: "^(\\w*)(?:\\(([\\w\\$\\.\\-\\*\\s]*)\\))?\\:\\s(.*)$" pattern: "^(\\w*)(?:\\(([\\w\\$\\.\\-\\*\\s]*)\\))?\\:\\s(.*)$"
pattern_maps: pattern_maps:

1
.gitignore vendored
View File

@ -3,5 +3,4 @@
/node_modules /node_modules
/internal/server/assets/dist/* /internal/server/assets/dist/*
dist/ dist/
/CHANGELOG.md
/tools /tools

View File

@ -9,6 +9,8 @@ GITCHLOG_ARGS ?=
SHELL := /bin/bash SHELL := /bin/bash
RUN_INSTALL_TESTS ?= yes RUN_INSTALL_TESTS ?= yes
FORMIDABLE_VERSION := 0.0.5
.PHONY: help .PHONY: help
help: ## Display this help help: ## Display this help
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
@ -60,9 +62,31 @@ node_modules:
release: deps release: deps
( set -o allexport && source .env && set +o allexport && VERSION=$(GORELEASER_VERSION) curl -sfL https://goreleaser.com/static/run | bash /dev/stdin $(GORELEASER_ARGS) ) ( set -o allexport && source .env && set +o allexport && VERSION=$(GORELEASER_VERSION) curl -sfL https://goreleaser.com/static/run | bash /dev/stdin $(GORELEASER_ARGS) )
.PHONY: start-release
start-release:
#git flow release start $(FORMIDABLE_VERSION)
# Update package.json version
jq '.version = "$(FORMIDABLE_VERSION)"' package.json | sponge package.json
git add package.json
git commit -m "chore: bump to version $(FORMIDABLE_VERSION)"
# Generate updated changelog
$(MAKE) GITCHLOG_ARGS='--next-tag $(FORMIDABLE_VERSION)' changelog
git add CHANGELOG.md
git commit -m "chore: update changelog for version $(FORMIDABLE_VERSION)"
echo "Commit you additional modifications then execute 'make finish-release'"
.PHONY: finish-release
finish-release:
git flow release finish -m "v$(FORMIDABLE_VERSION)"
git push --all
git push --tags
.PHONY: changelog .PHONY: changelog
changelog: changelog:
go run -mod=readonly github.com/git-chglog/git-chglog/cmd/git-chglog@v0.15.1 $(GITCHLOG_ARGS) go run -mod=readonly github.com/git-chglog/git-chglog/cmd/git-chglog@v0.15.1 $(GITCHLOG_ARGS) > CHANGELOG.md
install-git-hooks: install-git-hooks:
git config core.hooksPath .githooks git config core.hooksPath .githooks

View File

@ -6,6 +6,8 @@ Web-based - but terminal compatible ! - little form editor using [JSONSchema](ht
The generated web UI does not use Javascript and can be used with terminal browsers like [w3m](https://en.wikipedia.org/wiki/W3m) or [lynx](https://en.wikipedia.org/wiki/Lynx_(web_browser)). The generated web UI does not use Javascript and can be used with terminal browsers like [w3m](https://en.wikipedia.org/wiki/W3m) or [lynx](https://en.wikipedia.org/wiki/Lynx_(web_browser)).
> ⚠ Formidable is currently in a very alpha stage ! Expect breaking changes...
## Install ## Install
### Manually ### Manually
@ -93,6 +95,10 @@ echo '{}' | FORMIDABLE_BROWSER="firefox" frmd \
> TODO: Write doc + example > TODO: Write doc + example
## Changelog
[See `CHANGELOG.md`](./CHANGELOG.md)
## Licence ## Licence
AGPL-3.0 AGPL-3.0