Skip to content
This repository has been archived by the owner on Jul 12, 2022. It is now read-only.

Commit

Permalink
Merge pull request #93 from viniciusramosdefaria/feature/changelog
Browse files Browse the repository at this point in the history
[FEATURE] Adding changelog to pipeline
  • Loading branch information
Marcos Guimarães authored May 20, 2020
2 parents c9f21b2 + 41e82ae commit fd266b8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
10 changes: 9 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ references:
images:
go: &GOLANG_IMAGE cimg/go:1.14
python: &PYTHON_IMAGE circleci/python:2.7-stretch
ruby: &RUBY_IMAGE cimg/ruby:2.6.5

paths:
test-results: &TEST_RESULTS_DIR bin
Expand Down Expand Up @@ -46,6 +47,12 @@ executors:
user: root
working_directory: /workspace

release-executor:
docker:
- image: *RUBY_IMAGE
user: root
working_directory: /workspace

jobs:
# Runs Go linters
lint:
Expand Down Expand Up @@ -148,7 +155,7 @@ jobs:
release:
environment:
<<: *ENVIRONMENT
executor: delivery-executor
executor: release-executor
steps:
- checkout
- run:
Expand Down Expand Up @@ -187,3 +194,4 @@ workflows:
<<: *FILTERS_RELEASE
requires:
- build

6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,12 @@ build-circle:
release:
git config --global user.email "$(GIT_EMAIL)"
git config --global user.name "$(GIT_NAME)"
gem install github_changelog_generator
github_changelog_generator -u zupit -p ritchie-cli --token $(GIT_PASSWORD) --enhancement-labels feature,Feature --exclude-labels duplicate,question,invalid,wontfix
git add .
git commit --allow-empty -m "release"
git commit --allow-empty -m "[ci skip] release"
git push $(GIT_REMOTE) HEAD:release-$(RELEASE_VERSION)
git tag -a $(RELEASE_VERSION) -m "release"
git tag -a $(RELEASE_VERSION) -m "$(RELEASE_VERSION)"
git push $(GIT_REMOTE) $(RELEASE_VERSION)
curl --user $(GIT_USERNAME):$(GIT_PASSWORD) -X POST https://api.github.com/repos/ZupIT/ritchie-cli/pulls -H 'Content-Type: application/json' -d '{ "title": "Release $(RELEASE_VERSION) merge", "body": "Release $(RELEASE_VERSION) merge with master", "head": "release-$(RELEASE_VERSION)", "base": "master" }'

Expand Down

0 comments on commit fd266b8

Please sign in to comment.