New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fastlane][lanemanager] Fastlane command suggestion improvement when running using bundler #18515
[fastlane][lanemanager] Fastlane command suggestion improvement when running using bundler #18515
Conversation
…running using bundler
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice one! LGTM
I have a minor suggestion. Please address if it makes sense to you🙇
@@ -107,12 +107,13 @@ def self.choose_lane(ff, platform) | |||
|
|||
puts(table) | |||
|
|||
fastlane_command_prefix = Helper.bundler? ? "bundle exec " : "" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"#{fastlane_command_prefix}fastlane"
It's not a big deal but I prefer not to see a variable interpolated and a string literal combined, like above, as I might wonder if there is a whitespace between those two. What do you think about composing all the command name here so that my small concern is resolved? 🙂
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 #{selection}` 🚀.") | ||
UI.important("Running lane `#{selection}`. Next time you can do this by directly typing `#{fastlane_command_prefix}fastlane #{selection}` 🚀.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Take in mind to change this if taking @ainame's suggestions
@@ -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 🚀") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And this 🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love this! Thanks for improving this 😊 I appreciate all of your contributions 😍
Hey @crazymanish 👋 Thank you for your contribution to fastlane and congrats on getting this pull request merged 🎉 Please let us know if this change requires an immediate release by adding a comment here 👍 |
Congratulations! 🎉 This was released as part of fastlane 2.181.0 🚀 |
Checklist
bundle exec rspec
from the root directory to see all new and existing tests passbundle exec rubocop -a
to ensure the code style is validMotivation and Context
bundle exec fastlane
commands provide us the wrong suggestions.Description
bundle exec
prefix if Fastlane is run using bundlerTesting Steps
bundle install
MyApp.zip
Screenshots