diff --git a/.toys/release/.lib/release_requester.rb b/.toys/release/.lib/release_requester.rb index 9152f737..6dbb6ec5 100644 --- a/.toys/release/.lib/release_requester.rb +++ b/.toys/release/.lib/release_requester.rb @@ -94,10 +94,7 @@ def determine_last_version end def analyze_messages - unless @last_version - @others << "Initial release." - return - end + return unless @last_version @utils.log("Analyzing commit messages since last version ...") dir = @utils.gem_directory(@gem_name) dir = "#{dir}/" unless dir.end_with?("/") @@ -191,6 +188,10 @@ def determine_new_version def build_changelog_entries @changelog_entries = [] + unless @last_version + @changelog_entries << "Initial release." + return + end unless @breaks.empty? @breaks.each do |line| @changelog_entries << "* BREAKING CHANGE: #{line}"