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
rvm list known doesn't work with PAGER="less -RM" #899
Comments
@hoelzro Please provide a gist of
I am on a Macbook Pro as well and it works fine here, so something is going on over there, as shown by
|
@deryldoucette Did you try it with PAGER set to 'less -RM', like the subject says? |
Actually no, because you don't set params to the pager in PAGER. If you must use params, you make an alias like so
The PAGER variable is only for defining the binary to use, not any additional params. You do that with an alias, as shown above. |
@mpapis not sure there is a real need to be able to have RVM violate the unix premise that PAGER should only be the binary name and not include params. However, the reason it fails under RVM is due to
(Line 382 of $rvm_path/scripts/utility) which causes it to be evaluated as a full binary name. |
Where is this premise documented that PAGER must be an executable name? What other program(s) follow this premise and fail to operate when PAGER is set to somethine like 'less -RM'? |
we have two problems here, and I think the best solution to it is an array:
OR:
but I'm not sure how this will work with other software as basically before OSX |
@hoelzro That has been a unix basic tenant since I was taught unix in the early 80s, and was taught to me by both commercial and open source communities involved with unix since their inception! You don't have to agree with it, just know that its been so. It wasn't until the advent of Linux that we started finding this changing, and Linux is not the end all be-all of Unix. The 'premise', to use your word, to not include params in core (PAGER is one of the oldest OS variables I know of) vars is for compatibility, and to use shell aliases or batch files to override. The reasoning for this is demonstrated by your current issue. Since a parameter which describes the binary to use, and demonstrated by @mpapis 's common use pattern, can cause compatibility issues and behaviour as you're showing, this is why shell aliases and script overrides are the normal methods for overriding. As @mpapis also has shown, spaces were not used because the OS didn't know how to handle them, and even today chokes on them quite often even though we've has spaces in file and directory names for a long time now. Adding parameters in the vars like that required the use of the very thing that caused issues... spaces. As I said, you don't have to agree with that 'premise', just know this is where it comes from, and is still used (in mixed mode and with mixed results) today. |
@mpapis btw, I agree with the change you just proposed. |
@deryldoucette You make a good argument. I don't fully agree (I don't see a problem with allowing this functionality), but it's not my project and now I understand where you're coming from. |
I just wanted to report the same issue because I have $PAGER set to Anyway, the issue is easily solved locally through a wrapper script
and |
@FooBarWidget the problem is that |
this should temporally fix it, but rescheduling to rvm2 for full fix |
Just what it sounds like.
The text was updated successfully, but these errors were encountered: