Cleaning up, did rvm implode, installed fresh rvm with --ruby so I have 2.0.0 installed.
When trying rvm install ruby-1.9.3 --autolibs=4, the installation hangs right after the message that the src is being extracted. This happens with 1.9.3, ruby-1.9.3-p392, and 1.9.2 as well. I get a couple of dots, and then nothing further happens. Any suggestions?
Results with --debug on a 1.9.2 attempt.
$ rvm --debug install ruby-1.9.2 --autolibs=4
ruby-1.9.2 - install
Searching for binary rubies, this might take some time.
Remote file does not exist https://rvm.io/binaries/osx/10.7/x86_64/ruby-1.9.2-p320.tar.bz2
Remote file does not exist http://jruby.org.s3.amazonaws.com/downloads/ruby-1.9.2-p320.tar.bz2
Remote file does not exist http://binaries.rubini.us/osx/10.7/x86_64/ruby-1.9.2-p320.tar.bz2
rvm_remote_server_url3 not found
No remote file name found
No binary rubies available for: osx/10.7/x86_64/ruby-1.9.2-p320.
Continuing with compilation. Please read 'rvm mount' to get more information on binary rubies.
__rvm_setup_compile_environment_setup ruby-1.9.2-p320
rvm_autolibs_flag=4
__rvm_setup_compile_environment_requirements ruby-1.9.2-p320
Installing requirements for osx, might require sudo password.
requirements code for osx loaded
requirements code for osx_brew loaded
brew seems to be writable
Already up-to-date.
Found required packages: autoconf, automake, libtool, pkg-config, libyaml, readline, libxml2, libxslt, libksba, openssl, sqlite.
Certificates in '/usr/local/etc/openssl/cert.pem' already are up to date.
rvm_configure_flags+=( --with-opt-dir=/usr/local/opt/libyaml )
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/readline/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/readline/lib:
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/libxml2/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/libxml2/lib:
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/libxslt/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/libxslt/lib:
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/libksba/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/libksba/lib:
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/openssl/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/openssl/lib:
__rvm_update_configure_env(1):CFLAGS=-I/usr/local/opt/sqlite/include:
__rvm_update_configure_env(1):LDFLAGS=-L/usr/local/opt/sqlite/lib:
__rvm_setup_compile_environment_osx_compiler ruby-1.9.2-p320
__rvm_setup_compile_environment_architectures ruby-1.9.2-p320
__rvm_setup_compile_environment_gcc47plus ruby-1.9.2-p320
__rvm_setup_compile_environment_bison ruby-1.9.2-p320
__rvm_setup_compile_environment_smartos ruby-1.9.2-p320
__rvm_setup_compile_environment_sunos ruby-1.9.2-p320
__rvm_setup_compile_environment_openbsd ruby-1.9.2-p320
__rvm_setup_compile_environment_auto_conf_make ruby-1.9.2-p320
__rvm_setup_compile_environment_flags_docs ruby-1.9.2-p320
__rvm_setup_compile_environment_flags_tcltk ruby-1.9.2-p320
__rvm_setup_compile_environment_flags_shared_static ruby-1.9.2-p320
__rvm_setup_compile_environment_flags_threads ruby-1.9.2-p320
found compiler: gcc-4.2
Installing Ruby from source to: /Users/jfnixon/.rvm/rubies/ruby-1.9.2-p320, this may take a while depending on your cpu(s)...
ruby-1.9.2-p320 - #downloading ruby-1.9.2-p320, this may take a while depending on your connection...
No archive, downloading
Running(11): curl --fail --location --max-redirs 10 --create-dirs -C - -o ruby-1.9.2-p320.tar.bz2 http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.2-p320.tar.bz2
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 8770k 100 8770k 0 0 177k 0 0:00:49 0:00:49 --:--:-- 123k
Downloaded archive checksum matched.
Log file: /Users/jfnixon/.rvm/log/ruby-1.9.2-p320/1366859728_extract.log
ls: /Users/jfnixon/.rvm/log/ruby-1.9.2-p320/1366859728_extract.log: No such file or directory
remove[ny]? y
[2013-04-24 23:15:34] __rvm_package_extract
__rvm_package_extract ()
{
rvm_debug __rvm_package_extract:$#: "$#";
typeset __tempdir __path __file __return;
__return=0;
__tempdir="$( TMPDIR="${rvm_tmp_path}" mktemp -d -t rvm-tmp.XXXXXXXXX )";
__rvm_package_extract_run "$1" "$__tempdir" || __return=$?;
if (( __return == 0 )); then
for __path in "$__tempdir"/*;
do
__file="${__path##*/}";
if [[ -n "${__file}" && -e "$2/${__file}" ]]; then
\rm -rf "$2/${__file}" || __return=$?;
fi;
\mv -f "${__path}" "$2/" || __return=$?;
done;
fi;
if [[ -n "$__tempdir" ]]; then
\rm -rf "$__tempdir";
fi;
return $__return
}
current path: /Users/jfnixon/.rvm/src
command(3): __rvm_package_extract /Users/jfnixon/.rvm/archives/ruby-1.9.2-p320.tar.bz2 /Users/jfnixon/.rvm/tmp/rvm_src_71265
ruby-1.9.2-p320 - #extracting ruby-1.9.2-p320 to /Users/jfnixon/.rvm/src/ruby-1.9.2-p320..^C
__rvm_rm_rf already gone: /Users/jfnixon/.rvm/tmp/71265*
looks like a endless loop, bugs should be reported to RVM directly => http://bit.ly/rvm-issues
I had this problem as well. I waited more than an hour for an operation that should have been completed in under 4 minutes. As it tuned out, for some reason a different version for ruby was installed on my Mac, outside of rvm. A simple rm /usr/bin/ruby did the trick.
Related
Why does nvm is added before /home/user/.rvm/gems/ruby-2.2.3/bin
in PATH ?
echo $PATH
/home/user/.rvm/bin:/home/user/.nvm/versions/node/v5.1.0/bin:/home/user/.rvm/gems/ruby-2.2.3/bin:/home/user/.rvm/gems/ruby-2.2.3#global/bin:/home/user/.rvm/rubies/ruby-2.2.3/bin:/home/user/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/user/.rvm/bin
My .zshrc file end looks like this
export NVM_DIR="/home/user/.nvm"
[[ -s "$NVM_DIR/nvm.sh" ]] && . "$NVM_DIR/nvm.sh" # This loads nvm
export PATH="$HOME/.rvm/bin:$PATH" # Add RVM to PATH for scripting
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
I get the following error because of that.
rvm -v
Warning! PATH is not properly set up, '/home/user/.rvm/gems/ruby-2.2.3/bin' is not at first place,
usually this is caused by shell initialization files - check them for 'PATH=...' entries,
it might also help to re-add RVM to your dotfiles: 'rvm get stable --auto-dotfiles',
to fix temporarily in this shell session run: 'rvm use ruby-2.2.3'.
rvm 1.26.11 (master) by Wayne E. Seguin <wayneeseguin#gmail.com>, Michal Papis <mpapis#gmail.com> [https://rvm.io/]
rvm is expecting to be the first in your PATH. You can disable this warning so that you do not have this issue by adding the following line to your .rvmrc file:
rvm_silence_path_mismatch_check_flag=1
This should disable that warning.
Your .rvmrc file should be located at: ~/.rvmrc. Create it if it does not exist.
Now, make nvm the first in your PATH and place rvm after that.
My rvm is not working, probably due to an error. When I open new console, it says:
-bash: /Users/amorfis/.rvm/scripts/cd: line 14: syntax error near unexpected token `('
-bash: /Users/amorfis/.rvm/scripts/cd: line 14: ` cd() { __zsh_like_cd cd "$#" ; }'
It's hard to say where the script .rvm/scripts/cd is called. When I remove this line from ~/.bash_profile:
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
there is no error. But when I issue source $HOME/.rvm/scripts/rvm... still there is no error.
My system is Mac OS X 10.9.4
rvm --version:
rvm 1.25.29 (stable) by Wayne E. Seguin <wayneeseguin#gmail.com>, Michal Papis <mpapis#gmail.com> [https://rvm.io/]
UPDATE
Other scripts in ~/.rvm/scripts:
alias
aliases
autolibs
base
cd
cleanup
cli
completion
cron
db
disk-usage
docs
env
extras
fetch
fix-permissions
functions
gemsets
group
hash
help
hook
info
initialize
install
irbrc
irbrc.rb
list
maglev
manage
migrate
monitor
mount
notes
osx-ssl-certs
override_gem
patches
pkg
prepare
repair
requirements
rtfm
rubygems
rvm
set
snapshot
tools
upgrade
version
wrapper
zsh
My ~/.bash_profile looks like this:
#...not important stuff
source ~/.bashrc
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
And in my ~/.bashrc I have this line (and few others):
[ -s "/Users/amorfis/.scm_breeze/scm_breeze.sh" ] && source "/Users/amorfis/.scm_breeze/scm_breeze.sh"
When I remove this line, the error is also gone. And again, it still doesn't show when I run source ~/.scm_breeze/scm_breeze.sh
Scm breeze is installed from here: https://github.com/ndbroadbent/scm_breeze
In source ~/.scm_breeze/scm_breeze.sh there is such piece of code:
if ! type ruby > /dev/null 2>&1; then
echo "Now in if"
# If Ruby is not installed, fall back to the
# slower bash/zsh implementation of 'git_status_shortcuts'
source "$scmbDir/lib/git/fallback/status_shortcuts_shell.sh"
fi
I expected the "if" statement is the problem. So I did this. Added such code before the if:
echo "Now lets try"
if ! type ruby > /dev/null 2>&1; then
echo "trying"
fi
echo "tried"
and inside if, as the first line in the block:
echo "Now in if"
This was the output:
Now lets try
tried
-bash: /Users/amorfis/.rvm/scripts/cd: line 14: syntax error near unexpected token `('
-bash: /Users/amorfis/.rvm/scripts/cd: line 14: ` cd() { __zsh_like_cd cd "$#" ; }'
So it looks like scm_breeze.sh is ok. The problem must be in .rvm, but only when scm_breeze.sh is run.
UPDATE 2:
The beginning of the .rvm/scripts/cd script looks like this:
#!/usr/bin/env bash
# Source a .rvmrc file in a directory after changing to it, if it exists. To
# disable this feature, set rvm_project_rvmrc=0 in /etc/rvmrc or $HOME/.rvmrc
case "${rvm_project_rvmrc:-1}" in
1|cd)
# clonned from git#github.com:mpapis/bash_zsh_support.git
source "$rvm_scripts_path/extras/bash_zsh_support/chpwd/function.sh"
# not using default loadign to support older Zsh
[[ -n "${ZSH_VERSION:-}" ]] &&
__rvm_version_compare "$ZSH_VERSION" -gt 4.3.4 ||
{
cd() { __zsh_like_cd cd "$#" ; }
popd() { __zsh_like_cd popd "$#" ; }
pushd() { __zsh_like_cd pushd "$#" ; }
}
I'd add this in as a comment, but I don't have the reputation to do so. I tried the answer from blob, but it didn't work.
I don't see the "scm_breeze-line", that Riaan Burger was talking about. Has anyone figured out an answer to this?
My error is pretty much the same:
/Users/myusername/.rvm/scripts/cd:14: defining function based on alias `cd' [ruby-2.3.3]
/Users/myusername/.rvm/scripts/cd:14: parse error near `()'
and line #14 says the same:
11 [[ -n "${ZSH_VERSION:-}" ]] &&
12 __rvm_version_compare "$ZSH_VERSION" -gt 4.3.4 ||
13 {
14 cd() { __zsh_like_cd cd "$#" ; }
15 popd() { __zsh_like_cd popd "$#" ; }
16 pushd() { __zsh_like_cd pushd "$#" ; }
17 }
I just ran into the same problem. The solution was to ensure the scm_breeze line executes after all the rvm ones.
Hit the same problem today, but the problem had nothing to do with scm_breeze in my case. If anyone stumbled onto this answer from google or some other place, maybe it'll help you.
Shortly after switching to OSX from Win7 I've been happily modifying anything and everything without necessarily understanding what I'm doing. Amongst other things, I've edited .bashrc as root (not the one from profile, rather the one located in /etc/.bashrc) and aliased cd like that:
alias cd='cd -P'
Never had problems with it before installing RVM, so if you were as root-happy as I once was, it might be worth checking whether you left yourself such a gift in the past.
I've moved said line into ~/.bash_profile and since then RVM happily runs without errors.
So basically what I did,
Step 1) Get a clone from SCM_BREEZE :-
git clone https://github.com/scmbreeze/scm_breeze.git
Step 2) Get a reference from Author's Doc (Link for Docs) and wrote few commands inside my local git repository's terminal,
. "$HOME/.scm_breeze/scm_breeze.sh"
update_scm_breeze
gs
It will update you scm breeze from github and patch your files if any
Your Git Status Command
N you are good to go...
Hope so it would help you now :)
I don't have a ~/.rvm file even after I upgrade my version of RVM using:
bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)
This command produces the following. How can I make sure a .rvm folder is created?
Upgrading the RVM installation in /opt/t/rvm/
chown: rvm: illegal group name
chown: rvm: illegal group name
RVM PATH line found in /Users/ros/.bashrc /Users/roseperrone/.zshrc.
RVM sourcing line found in /Users/ros/.bash_profile /Users/roseperrone/.zprofile.
Upgrade Notes:
* No new notes to display.
# RVM: Shell scripts enabling management of multiple ruby environments.
# RTFM: https://rvm.io/
# HELP: http://webchat.freenode.net/?channels=rvm (#rvm on irc.freenode.net)
# Cheatsheet: http://cheat.errtheblog.com/s/rvm
# Screencast: http://screencasts.org/episodes/how-to-use-rvm
# In case of any issues run 'rvm requirements' or read 'rvm notes'
Upgrade of RVM in /opt/t/rvm/ is complete.
You don't have a ~/.rvm, because you installed rvm to /opt/t/rvm/.
You may either just live with that and use /opt/t/rvm/ instead of ~/.rvm. Or remove rvm completely and make a new install (which should then default to ~/.rvm).
I'm having a hard time getting rvm to install on Mint. I tried the instructions at:
https://rvm.beginrescueend.com/rvm/install/
The first step proceeds without incident. However, when I try to run source ~/.bash_profile, I get an error message stating that no such directory exists. I can restart the terminal, but it still says that "The program 'rvm' is currently not installed...."
A .rvm directory in now present in my home directory and the binary is there. I'm suspecting that this means that I need to add something in my .bashrc (or somewhere else) to tell the OS where to look for executables. But I'm still a little new at Linux and am uncertain where exactly it needs to go or what it should be.
The Answer in the same site:
echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function' >> ~/.bash_profile
it works for me.
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function
Looks like this needs to be tacked onto the end of the .bashrc file if it isn't present.
I am new to ruby programming and want to install RVM. I have followed steps provided in https://rvm.beginrescueend.com/rvm/install/, but i am not able to install it perfectly
During my installation i have followed steps as given below
STEP1 => user$ bash -s stable < <(curl -sk https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)
O/p
Downloading RVM from wayneeseguin branch stable
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 125 100 125 0 0 19 0 0:00:06 0:00:06 --:--:-- 120
100 796k 100 796k 0 0 64804 0 0:00:12 0:00:12 --:--:-- 186k
Installing RVM to /usr/share/ruby-rvm/
installing - /usr/share/ruby-rvm/man/man1/rvm.1.gz -
installing - /usr/share/ruby-rvm/man/man1/rvm.1 -
RVM system user group 'rvm' exists, proceeding with installation.
# RVM: Shell scripts enabling management of multiple ruby environments.
# RTFM: https://rvm.beginrescueend.com/
# HELP: http://webchat.freenode.net/?channels=rvm (#rvm on irc.freenode.net)
# Screencast: http://screencasts.org/episodes/how-to-use-rvm
# In case of any issues read output of 'rvm requirements' and/or 'rvm notes'
Installation of RVM in /usr/share/ruby-rvm/ is complete.
# user,
#
# Thank you for using RVM!
# I sincerely hope that RVM helps to make your life easier and more enjoyable!!!
#
# ~Wayne
Then i have fired "user$ rvm requirements"
It gives me output me like
Additional Dependencies:
# For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
ruby: /usr/bin/apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion
# For JRuby, install the following:
jruby: /usr/bin/apt-get install curl g++ openjdk-6-jre-headless
jruby-head: /usr/bin/apt-get install ant openjdk-6-jdk
# For IronRuby, install the following:
ironruby: /usr/bin/apt-get install curl mono-2.0-devel
But when after installing these dependencies using apt-get it gives me error while firing command "user$ rvm list"
bash: /usr/bin/rvm: No such file or directory
and after that i am not able to access rvm.....
Please guide me for installing rvm with specific way
I am using ubuntu 11.10 beta
fire a command source /usr/local/rvm/scripts/rvm
and then go with
type rvm | head -1
and got the output like
rvm is a function.
And after that i have run rvm use 1.9.2 --default and i got the version of ruby to 1.9.2