diff --git a/.circleci/config.yml b/.circleci/config.yml index 890d357..ce1d3aa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -132,12 +132,15 @@ jobs: - run: name: Generate Changelog command: | + tag=$(git describe --abbrev=0 --tags `git rev-list --tags --skip=1 --max-count=1` || true) + since_tag=$(if [ "${tag}" ]; then echo "--since-tag ${tag}"; fi) + docker pull timfallmk/github-changelog-generator docker run --name changelog timfallmk/github-changelog-generator \ -u ${CIRCLE_PROJECT_USERNAME} \ -p ${CIRCLE_PROJECT_REPONAME} \ -t ${GITHUB_TOKEN} \ - --since-tag $(git describe --abbrev=0 --tags `git rev-list --tags --skip=1 --max-count=1`) + ${since_tag} docker cp changelog:/usr/local/src/your-app/CHANGELOG.md ./ - run: name: Create Release @@ -161,12 +164,17 @@ workflows: jobs: - build - publish-edge: + context: vapor-auto requires: - build filters: branches: only: master - - publish-release: - <<: *tag-filters - release: + context: vapor-auto <<: *tag-filters + - publish-release: + context: vapor-auto + <<: *tag-filters + requires: + - release diff --git a/Makefile b/Makefile index cfc08d5..b10ab4d 100644 --- a/Makefile +++ b/Makefile @@ -64,7 +64,7 @@ fmt: ## Run goimports on all go files .PHONY: github-tag github-tag: ## Create and push a tag with the current plugin version - git tag -a ${PLUGIN_VERSION} -m "${PLUGIN_NAME} version ${PLUGIN_VERSION}" + git tag -a ${PLUGIN_VERSION} -m "${PLUGIN_NAME} plugin version ${PLUGIN_VERSION}" git push -u origin ${PLUGIN_VERSION} .PHONY: lint @@ -74,8 +74,13 @@ ifndef HAS_LINT gometalinter --install endif @ # disable gotype: https://github.com/alecthomas/gometalinter/issues/40 - gometalinter ./... --tests --vendor --deadline=5m \ - --disable=gotype --disable=gocyclo + gometalinter ./... \ + --disable=gotype --disable=gocyclo \ + --tests \ + --vendor \ + --sort=severity \ + --aggregate \ + --deadline=5m .PHONY: setup setup: ## Install the build and development dependencies and set up vendoring