Rails argument list too long

I read a lot of posts about this error, but I can not understand anything. For some reason, all of my rail applications see this error when I run almost anything on the command line ( rails s , gem list , sudo gem update --system , etc.)

/Users/username/.rvm/bin/gem: line 6: /Users/username/.rvm/bin/gem: The list of arguments is too long

/Users/username/.rvm/bin/gem: line 6: /Users/username/.rvm/bin/gem: Unknown error: 0

The file to which it points is as follows:

 #!/usr/bin/env bash if [[ -s "/Users/username/.rvm/environments/ ruby-1.9.2-p180@rails31 " ]] then source "/Users/username/.rvm/environments/ ruby-1.9.2-p180@rails31 " exec gem " $@ " #The line it points at else echo "ERROR: Missing RVM environment file: '/Users/username/.rvm/environments/ruby- 1.9.2-p180@rails31 '" >&2 exit 1 fi 

I am really new to rails, so maybe this is something simple, but I can’t do anything.

UPDATE:

I reinstalled rvm, but now I get a new error. I tried to install another version of ruby, and everything was fine so far:

 ERROR: Error running ' ./configure --prefix="/Users/username/.rvm/usr" ', please read /Users/username/.rvm/log/ruby-1.9.2-p180/yaml/configure.log Compiling yaml in /Users/username/.rvm/src/yaml-0.1.3. ERROR: Error running '/usr/bin/make ', please read /Users/username/.rvm/log/ruby-1.9.2-p180/yaml/make.log Installing yaml to /Users/username/.rvm/usr ERROR: Error running '/usr/bin/make install', please read /Users/username/.rvm/log/ruby-1.9.2-p180/yaml/make.install.log ruby-1.9.2-p180 - #configuring ERROR: Error running ' ./configure --prefix=/Users/username/.rvm/rubies/ruby-1.9.2-p180 --enable-shared --disable-install-doc --with-libyaml-dir=/Users/username/.rvm/usr ', please read /Users/username/.rvm/log/ruby-1.9.2-p180/configure.log ERROR: There has been an error while running configure. Halting the installation. 
+2
source share
4 answers

From the comments:

  • reinstall RVM, rvm implode
  • Then the same installation process was installed because 1.9.3-p0 expects a GCC version other than LLVM, which is no longer included in Xcode version 4.2. rvm install 1.9.3-p0 --with-gcc = clang
+4
source

Reinstalling RVM helped me with this problem.

 rvm implode bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer) 
+2
source

I had a similar problem before I installed RVM (or parts of it) using sudo.

What worked for me was to remove all .rvm from your user folder and reinstall using non-sudo.

+1
source

create .rvmrc for your project using an updated version of ruby ​​or use rvm 1.9.3

0
source

All Articles