-
Notifications
You must be signed in to change notification settings - Fork 97
rbenv breaks an assumption in bin/dev
.
#87
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
Comments
Are there any considerations here re: Windows / WSL we need to account for if we use grep + wc? |
That's an excellent question. I've got an engineer who's using WSL that I can ask. I will update the ticket when I have an answer. Another option might be something like: if ! type rbenv &> /dev/null
then
if ! command -v foreman &> /dev/null
then
# ...
fi
else
if ! foreman version >/dev/null
then
# ...
fi
fi It's a little more cumbersome to be sure, but it seems like it would be viable. I think it would neatly compartmentalize any potential quirks / changes of semantics to just us |
I'm informed by my colleague that when run from a Linux terminal in WSL, |
@dhh What can I do to move this forward? |
Could |
@t27duck That solution is compatible with |
Sounds like @t27duck's solution would do. Feel free to PR that. |
Done. |
Because rbenv uses shims, this line in the generated
bin/dev
script will always return true in an environment in whichforeman
has been installed in any gemset at any point, even if it's not in the current gemset:I've found this to be a viable alternative that I believe should work everywhere:
(The use of
grep
is because when foreman isn't installed,gem list
will produce an empty line of output.)The text was updated successfully, but these errors were encountered: