Skip to content

Commit

Permalink
chore: add tag_for_release task
Browse files Browse the repository at this point in the history
  • Loading branch information
bethesque committed Dec 18, 2017
1 parent 7b7d9fd commit b719342
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion script/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ bundle exec bump ${1:-minor} --no-commit
bundle exec rake generate_changelog
git add CHANGELOG.md lib/pact/mock_service/version.rb
git commit -m "chore(release): version $(ruby -r ./lib/pact/mock_service/version.rb -e "puts Pact::MockService::VERSION")" && git push
bundle exec rake release
bundle exec rake tag_for_release
9 changes: 9 additions & 0 deletions tasks/release.rake
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,15 @@ task :generate_changelog do
ConventionalChangelog::Generator.new.generate! version: "v#{Pact::MockService::VERSION}"
end

desc 'Tag for release'
task :tag_for_release do | t, args |
require 'pact/mock_service/version'
version = Pact::MockService::VERSION
command = "git tag -a v#{version} -m \"chore(release): version #{version}\" && git push origin v#{version}"
puts command
puts `#{command}`
end

desc 'Generate release notes'
task :generate_release_notes, [:tag] do | t, args |
require 'fileutils'
Expand Down

0 comments on commit b719342

Please sign in to comment.