ruby - Setting up env, OSX rbenv and bundle battle -


so have swapped on mac ubuntu , setting env has not been easy promised.

this process followed.

  1. installed xcode - went prefrences , downloaded command line tools
  2. then verified right version installed, running gcc --version

    i686-apple-darwin11-llvm-gcc-4.2 (gcc) 4.2.1 (based on apple inc. build 5658) (llvm build 2336.11.00) copyright (c) 2007 free software foundation, inc. free software; see source copying conditions.  there no warranty; not merchantability or fitness particular purpose. 
  3. then installed homebrew $ ruby -e "$(curl -fssl https://raw.github.com/mxcl/homebrew/go)"
  4. ran brew doctor , get

    your system ready brew.

5.installed git brew update + brew install git

6.linked pc git account via ssh

7.installed rbenv

$ brew update $ brew install rbenv $ brew install ruby-build 

added eval "$(rbenv init -)" .bash_profile file

  1. ran rbenv install -list see versions install , ran

    $ rbenv install 1.9.3-p327 $ rbenv global 1.9.3-p327 
  2. (i should have rehashed rbenv forgot) ran gem install bundler

  3. then went 1 of repo's , ran bundle install blew errors

    gem::installerror: better_errors requires ruby version >= 1.9.2. error occurred while installing better_errors (0.7.0), , bundler cannot continue. make sure `gem install better_errors -v '0.7.0'` succeeds before bundling. 

ran ruby -v , saw on 1.8.7 "balls" - exclaimed

  1. to remedy did following rbenv rehash

  2. ruby -v , got ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-darwin12.3.0] high fived myself

  3. then tried run bundle , same error comes ??

    $ bundle /usr/bin/bundle  $ gem /users/fortknokx/.rbenv/shims/gem 

so stand confused heck. said third day using mac , pretty new understanding $path sure made foul somewhere. advice open to.

ps have in .bash_profile

export path="/usr/local/bin:/usr/local/bin/sublime:~/bin:$path" eval "$(rbenv init -)" 

the problem seems you're using system ruby installed bundler, , not 1 installed rbenv ruby.

run ruby --version make sure rbenv ruby active, run gem install bundler followed rbenv rehash , try reinstalling gems , see if works.


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -