From 2920cac99fdeae186599d27913da2495d704d460 Mon Sep 17 00:00:00 2001 From: Manish Rathi Date: Thu, 8 Apr 2021 09:25:42 +0200 Subject: [PATCH 1/2] [fastlane][lanemanager] Fastlane command suggestion improvement when running using bundler --- fastlane/lib/fastlane/lane_manager.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fastlane/lib/fastlane/lane_manager.rb b/fastlane/lib/fastlane/lane_manager.rb index 4fd72a68da4..7cf4da749a2 100644 --- a/fastlane/lib/fastlane/lane_manager.rb +++ b/fastlane/lib/fastlane/lane_manager.rb @@ -107,12 +107,13 @@ def self.choose_lane(ff, platform) puts(table) + fastlane_command_prefix = Helper.bundler? ? "bundle exec " : "" i = UI.input("Which number would you like run?") i = i.to_i - 1 if i >= 0 && available[i] selection = available[i].last.pretty_name - UI.important("Running lane `#{selection}`. Next time you can do this by directly typing `fastlane #{selection}` 🚀.") + UI.important("Running lane `#{selection}`. Next time you can do this by directly typing `#{fastlane_command_prefix}fastlane #{selection}` 🚀.") platform = selection.split(' ')[0] lane_name = selection.split(' ')[1] @@ -123,7 +124,7 @@ def self.choose_lane(ff, platform) return platform, lane_name # yeah else - UI.user_error!("Run `fastlane` the next time you need to build, test or release your app 🚀") + UI.user_error!("Run `#{fastlane_command_prefix}fastlane` the next time you need to build, test or release your app 🚀") end end end From f14f363afa1637dd87e5d28b7f93fea51b091cd0 Mon Sep 17 00:00:00 2001 From: Manish Rathi Date: Sun, 11 Apr 2021 08:20:50 +0200 Subject: [PATCH 2/2] PR review fix --- fastlane/lib/fastlane/lane_manager.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fastlane/lib/fastlane/lane_manager.rb b/fastlane/lib/fastlane/lane_manager.rb index 7cf4da749a2..9aa49c85166 100644 --- a/fastlane/lib/fastlane/lane_manager.rb +++ b/fastlane/lib/fastlane/lane_manager.rb @@ -107,13 +107,13 @@ def self.choose_lane(ff, platform) puts(table) - fastlane_command_prefix = Helper.bundler? ? "bundle exec " : "" + fastlane_command = Helper.bundler? ? "bundle exec fastlane" : "fastlane" i = UI.input("Which number would you like run?") i = i.to_i - 1 if i >= 0 && available[i] selection = available[i].last.pretty_name - UI.important("Running lane `#{selection}`. Next time you can do this by directly typing `#{fastlane_command_prefix}fastlane #{selection}` 🚀.") + UI.important("Running lane `#{selection}`. Next time you can do this by directly typing `#{fastlane_command} #{selection}` 🚀.") platform = selection.split(' ')[0] lane_name = selection.split(' ')[1] @@ -124,7 +124,7 @@ def self.choose_lane(ff, platform) return platform, lane_name # yeah else - UI.user_error!("Run `#{fastlane_command_prefix}fastlane` the next time you need to build, test or release your app 🚀") + UI.user_error!("Run `#{fastlane_command}` the next time you need to build, test or release your app 🚀") end end end