-
Notifications
You must be signed in to change notification settings - Fork 245
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add release-notes make target
- Loading branch information
Showing
2 changed files
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# | ||
# Makefile fragment for displaying auto-generated documentation | ||
# | ||
|
||
GOTOOLS += golang.org/x/tools/cmd/godoc \ | ||
github.com/git-chglog/git-chglog/cmd/git-chglog | ||
GODOC ?= godoc | ||
GODOC_HTTP ?= "localhost:6060" | ||
|
||
CHANGELOG_CMD ?= git-chglog | ||
CHANGELOG_FILE ?= CHANGELOG.md | ||
RELEASE_NOTES_FILE ?= relnotes.md | ||
|
||
changelog: tools | ||
@echo "=== $(PROJECT_NAME) === [ changelog ]: Generating changelog..." | ||
@$(CHANGELOG_CMD) --silent -o $(CHANGELOG_FILE) | ||
|
||
docs: tools | ||
@echo "=== $(PROJECT_NAME) === [ docs ]: Starting godoc server..." | ||
@echo "=== $(PROJECT_NAME) === [ docs ]:" | ||
@echo "=== $(PROJECT_NAME) === [ docs ]: NOTE: This only works if this codebase is in your GOPATH!" | ||
@echo "=== $(PROJECT_NAME) === [ docs ]: godoc issue: https://github.com/golang/go/issues/26827" | ||
@echo "=== $(PROJECT_NAME) === [ docs ]:" | ||
@echo "=== $(PROJECT_NAME) === [ docs ]: Module Docs: http://$(GODOC_HTTP)/pkg/$(PROJECT_MODULE)" | ||
@$(GODOC) -http=$(GODOC_HTTP) | ||
|
||
release-notes: tools | ||
@echo "=== $(PROJECT_NAME) === [ release-notes ]: Generating release notes..." | ||
@mkdir -p $(SRCDIR)/tmp | ||
@$(CHANGELOG_CMD) --silent -o $(SRCDIR)/tmp/$(RELEASE_NOTES_FILE) v$(PROJECT_VER_TAGGED) | ||
|
||
.PHONY: docs changelog release-notes |