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
options:
commits:
# filters:
# Type:
# - feat
# - fix
# - perf
# - refactor
filters:
Type:
- feat
- fix
- perf
- refactor
commit_groups:
# title_maps:
# feat: Features
# fix: Bug Fixes
# perf: Performance Improvements
# refactor: Code Refactoring
title_maps:
feat: Features
fix: Bug Fixes
perf: Performance Improvements
refactor: Code Refactoring
header:
pattern: "^(\\w*)(?:\\(([\\w\\$\\.\\-\\*\\s]*)\\))?\\:\\s(.*)$"
pattern_maps:

1
.gitignore vendored
View File

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

View File

@ -9,6 +9,8 @@ GITCHLOG_ARGS ?=
SHELL := /bin/bash
RUN_INSTALL_TESTS ?= yes
FORMIDABLE_VERSION := 0.0.5
.PHONY: 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}'
@ -60,9 +62,31 @@ node_modules:
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) )
.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
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:
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)).
> ⚠ Formidable is currently in a very alpha stage ! Expect breaking changes...
## Install
### Manually
@ -93,6 +95,10 @@ echo '{}' | FORMIDABLE_BROWSER="firefox" frmd \
> TODO: Write doc + example
## Changelog
[See `CHANGELOG.md`](./CHANGELOG.md)
## Licence
AGPL-3.0