Skip to content

Commit

Permalink
Merge pull request #530 from hilary/retire-changelog
Browse files Browse the repository at this point in the history
Retire changelog
  • Loading branch information
bentranter authored Aug 1, 2019
2 parents 49c8268 + 69c39dd commit f99c968
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 31 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Change Log

Changelog moved to Release Notes in [Github Releases](https://github.com/digitalocean/doctl/releases)

## [1.24.1] = 2019-07-29

- PR #525 - @hilary - release containers to dockerhub
Expand Down
14 changes: 6 additions & 8 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,16 +123,14 @@ and let TravisCI run shellcheck for you.

### Cutting a release

1. Run `make changelog` and add the results to the [CHANGELOG](https://github.com/digitalocean/doctl/blob/master/CHANGELOG.md)
under the version you're going to release if they aren't already there.

1. Generate a PR, get it reviewed, and merge
1. Run `make changes` to review the changes since the last
release. Based on the changes, decide what kind of release you are
doing (bugfix, feature or breaking).
`doctl` follows [semantic versioning](semver.org), ask if you aren't sure.

1. Cut a release using `BUMP=(bugfix|feature|breaking) make bump_and_release`.
`doctl` follows [semantic versioning](semver.org), ask if
you aren't sure. `BUMP=bugfix` is an alias for `BUMP=patch`,
`BUMP=feature` is an alias for `BUMP=minor`, and `BUMP=breaking`
is an alias for `BUMP=major`.
(Bugfix, feature and breaking are aliases for semver's patch, minor and major.
BUMP will also accept `patch`, `minor` and `major`, if you prefer.)

#### Oops! What now?

Expand Down
46 changes: 23 additions & 23 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,13 @@ export CGO = 0

export GO111MODULE := on

# ORIGIN is used when testing release code
ORIGIN ?= origin
BUMP ?= patch

.PHONY: help
help:
@echo "==> describing make commands"
@echo "==> describe make commands"
@echo ""
@$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null |\
awk -v RS= -F: \
Expand All @@ -34,7 +38,7 @@ endif

.PHONY: _build
_build:
@echo "==> building doctl via go build"
@echo "=> building doctl via go build"
@echo ""
@mkdir -p builds
@cd cmd/doctl && env GOOS=$(GOOS) GOARCH=$(GOARCH) GOFLAGS=-mod=vendor \
Expand All @@ -43,7 +47,7 @@ _build:

.PHONY: native
native: _build
@echo "==> building local version"
@echo "==> build local version"
@echo ""
@mv $(OUT_D)/doctl_$(GOOS)_$(GOARCH) $(OUT_D)/doctl
@echo "built $(OUT_D)/doctl"
Expand All @@ -59,7 +63,7 @@ _base_docker_cntr:

.PHONY: docker_build
docker_build: _base_docker_cntr
@echo "==> building doctl in local docker container"
@echo "==> build doctl in local docker container"
@echo ""
@mkdir -p $(OUT_D)
@docker build -f Dockerfile.cntr . -t doctl_local
Expand All @@ -76,40 +80,40 @@ docker_build: _base_docker_cntr

.PHONY: test
test:
@echo "==> running tests"
@echo "==> run tests"
@echo ""
go test ./commands/... ./do/... ./pkg/... .

.PHONY: shellcheck
shellcheck:
@echo "==> analyzing shell scripts"
@echo "==> analyze shell scripts"
@echo ""
@scripts/shell_check.sh

CHANNEL ?= stable

.PHONY: _snap
_snap:
@echo "==> publishing snap"
@echo "=> publishing snap"
@echo ""
@CHANNEL=${CHANNEL} scripts/snap.sh

.PHONY: mocks
mocks:
@echo "==> updating mocks"
@echo "==> update mocks"
@echo ""
@scripts/regenmocks.sh

.PHONY: vendor
vendor:
@echo "==> vendoring dependencies"
@echo "==> vendor dependencies"
@echo ""
go mod vendor
go mod tidy

.PHONY: clean
clean:
@echo "==> removing build / release artifacts"
@echo "==> remove build / release artifacts"
@echo ""
@rm -rf builds

Expand All @@ -121,50 +125,46 @@ _install_github_release_notes:
_changelog: _install_github_release_notes
@scripts/changelog.sh

.PHONY: changelog
changelog: _install_github_release_notes
@echo "==> generating changelog"
.PHONY: changes
changes: _install_github_release_notes
@echo "==> list merged PRs since last release"
@echo ""
@changes=$(shell scripts/changelog.sh) && cat $$changes && rm -f $$changes

ORIGIN ?= origin

BUMP ?= patch

.PHONY: version
version:
@echo "==> determining doctl version"
@echo "==> doctl version"
@echo ""
@ORIGIN=${ORIGIN} scripts/version.sh

.PHONY: _install_sembump
_install_sembump:
@echo "==> installing/updating sembump tool"
@echo "=> installing/updating sembump tool"
@echo ""
@GO111MODULE=off go get -u github.com/jessfraz/junk/sembump

.PHONY: _bump_and_tag
_bump_and_tag: _install_sembump
@echo "==> BUMP=${BUMP} bumping and tagging version"
@echo "=> BUMP=${BUMP} bumping and tagging version"
@echo ""
@ORIGIN=${ORIGIN} scripts/bumpversion.sh

.PHONY: _release
_release:
@echo "==> releasing"
@echo "=> releasing"
@echo ""
@scripts/release.sh

.PHONY: bump_and_release
bump_and_release: _bump_and_tag
@echo "==> BUMP=${BUMP} bumping and releasing"
@echo "==> BUMP=${BUMP} bump tag and release"
@echo ""
@$(MAKE) _release
@$(MAKE) _snap

.PHONY: release
release:
@echo "==> releasing"
@echo "==> release most recent tag"
@echo ""
@$(MAKE) _release

Expand Down

0 comments on commit f99c968

Please sign in to comment.