class VersionManager::VersionTagger

Public Instance Methods

call(version) click to toggle source
# File lib/version_manager/version_tagger.rb, line 5
def call version
  logger.info "Committing and tagging..."
  tag version
  logger.info "Done"
  logger.info "Run `git push origin master --tags` to deploy your new tag (#{version.to_tag})"
end

Private Instance Methods

history_file() click to toggle source
# File lib/version_manager/version_tagger.rb, line 20
def history_file
  VersionManager.configuration.history_file
end
logger() click to toggle source
# File lib/version_manager/version_tagger.rb, line 28
def logger
  VersionManager.configuration.logger
end
tag(version) click to toggle source
# File lib/version_manager/version_tagger.rb, line 14
def tag version
  Git.add history_file, version_file
  Git.commit "Update version to #{version.to_tag}"
  Git.tag version.to_tag
end
version_file() click to toggle source
# File lib/version_manager/version_tagger.rb, line 24
def version_file
  VersionManager.configuration.version_file
end