deliver/lib/deliver/commands_generator.rb in fastlane_hotfix-2.165.1 vs deliver/lib/deliver/commands_generator.rb in fastlane_hotfix-2.187.0

- old
+ new

@@ -1,7 +1,8 @@ require 'commander' require 'fastlane/version' +require 'fastlane_core/ui/help_formatter' require_relative 'download_screenshots' require_relative 'options' require_relative 'module' require_relative 'generate_summary' @@ -46,11 +47,11 @@ program :version, Fastlane::VERSION program :description, Deliver::DESCRIPTION program :help, 'Author', 'Felix Krause <deliver@krausefx.com>' program :help, 'Website', 'https://fastlane.tools' program :help, 'Documentation', 'https://docs.fastlane.tools/actions/deliver/' - program :help_formatter, :compact + program :help_formatter, FastlaneCore::HelpFormatter global_option('--verbose') { FastlaneCore::Globals.verbose = true } global_option('--env STRING[,STRING2]', String, 'Add environment(s) to use with `dotenv`') always_trace! @@ -165,20 +166,20 @@ path = options[:metadata_path] || File.join(containing, 'metadata') res = Deliver::CommandsGenerator.force_overwrite_metadata?(options, path) return 0 unless res require 'deliver/setup' - app = options[:app] + app = Deliver.cache[:app] platform = Spaceship::ConnectAPI::Platform.map(options[:platform]) v = app.get_latest_app_store_version(platform: platform) if options[:app_version].to_s.length > 0 v = app.get_live_app_store_version(platform: platform) if v.version_string != options[:app_version] if v.nil? || v.version_string != options[:app_version] raise "Neither the current nor live version match specified app_version \"#{options[:app_version]}\"" end end - Deliver::Setup.new.generate_metadata_files(app, v, path) + Deliver::Setup.new.generate_metadata_files(app, v, path, options) end end default_command(:run)