Skip to content

Commit

Permalink
Add make release and instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
pseudomuto committed Feb 22, 2018
1 parent a118e98 commit 8b7aad8
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,10 @@ I don't want to be too dogmatic about this, but here are some general things I t
* Test are defined in `<package>_test` packages to ensure only the public interface is tested
* If you export something, make sure you add appropriate godoc comments

## Tagging a Release

* Set the `Version` in _version.go_
* Update CHANGELOG.md with the relevant changes
* `make release` - will commit everything, create a tag and push

[retool]: https://github.com/twitchtv/retool
11 changes: 10 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
.PHONY: bench setup test
.PHONY: bench release setup test

VERSION = $(shell cat version.go | sed -n 's/.*const Version = "\(.*\)"/\1/p')

setup:
$(info Synching dev tools and dependencies...)
Expand All @@ -18,3 +20,10 @@ test: fixtures/fileset.pb

test-ci: fixtures/fileset.pb bench
@retool do goverage -race -coverprofile=coverage.txt -covermode=atomic ./ ./utils

release:
@echo Releasing v${VERSION}...
git add CHANGELOG.md version.go
git commit -m "Bump version to v${VERSION}"
git tag -m "Version ${VERSION}" "v${VERSION}"
git push && git push --tags
4 changes: 4 additions & 0 deletions version.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package protokit

// Version describes the current version of protokit being used
const Version = "0.1.0-pre"

0 comments on commit 8b7aad8

Please sign in to comment.