Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Can't reinstall RVM after move/delete of $HOME/.rvm #1188

Closed
brauliobo opened this Issue · 19 comments

3 participants

@brauliobo

➜ ~ mv .rvm blah
➜ ~ curl -L https://get.rvm.io | bash -s stable
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 10009 100 10009 0 0 4266 0 0:00:02 0:00:02 --:--:-- 9774k
BASH 3.2.25 required (you have 4.1.5(1)-release)
➜ ~

@mpapis
Collaborator

this is of course a bug - but it shows another problem - you have bash 4.1 which is not supported, only bash 3.2.17+, 4.2+ and zsh 4.3.11+ is supported.

@brauliobo

hum, bash 4.1 the version present at debian 6, which is an important distribution...
but note that in this case i'm using zsh, even so bash is required...

@gucki

This bug prevents me to install rvm on a new debian squeeze system... :(

@gucki

To install rvm anway (works fine so far), just do:

curl -L https://get.rvm.io > a
# remove the lines inside the file a for the bash version check manually
cat a | bash -s stable --ruby
@mpapis
Collaborator

@gucki could you run the tests on your system to confirm it works as expected? You can find instructions for testing here: https://github.com/wayneeseguin/rvm/blob/master/HACKING.md

@gucki

I just followed the instructions and the tests are currently running. So far without error, as far as I can tell.

But there seems to be a bug? in the test suite.Even I did tf --text fast/* for which the README.md says it's not going to install any rubies (well, in fact the info for long/* says it's going to install rubies so I'd assuem fast/* does not) it's installing several rubies (1.9.2, 1.8.7, ...).

@gucki

BTW, here's my bash version (the standart one from latest debian squeeze):

bash --version
GNU bash, Version 4.1.5(1)-release (x86_64-pc-linux-gnu)
@gucki

And here's the error message when trying to install rvm:

root@vs16332:/# curl -L https://get.rvm.io | bash -s stable --ruby
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 10009  100 10009    0     0   6832      0  0:00:01  0:00:01 --:--:-- 25717
BASH 3.2.25 required (you have 4.1.5(1)-release)
@gucki

Tests just finished:

tf --text fast/*
##### starting test alias.
....
##### Processed commands 455 of 455, success tests 359 of 359.

Is there any need to run the long/* tests too?

@mpapis
Collaborator

Then 4.1.5 is officially supported now! There were some errors with it, but I guess they got fixed by improving code quality and ZSH support.

The version comparison will be fixed with 1.16.x

@mpapis
Collaborator

can someone test this one in bash 4.1:

[[ "$( printf "4.1.5(1)-release\n3.2.25\n" | sort -n -t"." | head -n 1 )" == "3.2.25" ]] && echo "ok" || echo "fail"
@gucki

Is this locale dependent?!

root@de:~# bash --version
GNU bash, Version 4.1.5(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2009 Free Software Foundation, Inc.
Lizenz GPLv3+: GNU GPL Version 3 oder jünger <http://gnu.org/licenses/gpl.html>

Dies ist freie Software.  Sie darf verändert und verteilt werden.
Für dieses Programm besteht keinerlei Garantie.
root@de:~# [[ "$( printf "4.1.5(1)-release\n3.2.25\n" | sort -n -t"." | head -n 1 )" == "3.2.25" ]] && echo "ok" || echo "fail"
fail


root@en:~# bash --version
GNU bash, version 4.1.5(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
root@en:~# [[ "$( printf "4.1.5(1)-release\n3.2.25\n" | sort -n -t"." | head -n 1 )" == "3.2.25" ]] && echo "ok" || echo "fail"
ok
@gucki

Some more information, just for completeness:

root@de:~# echo "$BASH_VERSION"
4.1.5(1)-release

root@en:~# echo "$BASH_VERSION"
4.1.5(1)-release
@gucki

Strange, isn't it?

root@de:~# printf "4.1.5(1)-release\n3.2.25\n" | sort -n -t"."
4.1.5(1)-release
3.2.25

root@en:~# printf "4.1.5(1)-release\n3.2.25\n" | sort -n -t"."
3.2.25
4.1.5(1)-release
@mpapis
Collaborator

try with:

 printf "4.1.5(1)-release\n3.2.25\n" | LC_LANG=C sort -n -t"."
@gucki

When using LANG instead of LC_LANG it works, otherwise not.

root@de:~# printf "4.1.5(1)-release\n3.2.25\n" | LC_LANG=C sort -n -t"."
4.1.5(1)-release
3.2.25

root@de:~# printf "4.1.5(1)-release\n3.2.25\n" | LANG=C sort -n -t"."
3.2.25
4.1.5(1)-release
@mpapis
Collaborator

ok, last test:

printf "4.1.5(1)-release\n3.2.25\n" | LC_ALL=C sort -n -t"."
@gucki

Works fine :)

@mpapis mpapis closed this in 564f8b7
@mpapis
Collaborator

opened to track merge status for 1.16.9

@mpapis mpapis reopened this
@mpapis mpapis closed this in 6d38534
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.