Quindi ho appena passato a mac da ubuntu e impostare l'env non è stato facile come promesso.Impostazione di env, OSX rbenv e bundle battle
questo è il processo che ho seguito.
- Xcode installato - poi andò in prefrences e scaricato il
command line tools
poi verificato che la versione corretta è stata installata, eseguendo
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. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
- poi installato homebrew
$ ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"
ran
brew doctor
e questo è quello che ottengoYour system is ready to brew.
5.installed git brew update
+ brew install git
6.linked mio pc al mio account git via ssh
7.Installed Rbenv
$ brew update
$ brew install rbenv
$ brew install ruby-build
aggiunto eval "$(rbenv init -)"
a il mio file .bash_profile
corse
rbenv install -list
per vedere tutte le versioni ho potuto installare e poi corse$ rbenv install 1.9.3-p327 $ rbenv global 1.9.3-p327
(avrei dovuto rehashed rbenv ma ho dimenticato) Allora ho fatto funzionare
gem install bundler
poi è andato in una delle il mio repo di e corse
bundle install
che soffiava con erroriGem::InstallError: better_errors requires Ruby version >= 1.9.2. An error occurred while installing better_errors (0.7.0), and Bundler cannot continue. Make sure that `gem install better_errors -v '0.7.0'` succeeds before bundling.
corse ruby -v
e vide che era sul 1.8.7 "palle" - esclamai
per porre rimedio a questo ho fatto la seguente
rbenv rehash
ruby -v
e ottenutoruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-darwin12.3.0]
poi dare il cinque mequindi provato a eseguire bundle e lo stesso errore si presenta ??
$ which bundle /usr/bin/bundle $ which gem /Users/fortknokx/.rbenv/shims/gem
quindi questo è ora dove mi trovo confuso come diamine. come ho detto questo è il mio terzo giorno con Mac e sono abbastanza nuovo per capire il $ PATH sono sicuro che ho fatto un fallo da qualche parte. qualsiasi consiglio sono aperto a
ps questo è quello che ho nel mio.bash_profile
export PATH="/usr/local/bin:/usr/local/bin/sublime:~/bin:$PATH"
eval "$(rbenv init -)"
luke your a ninja di sicuro! – TheLegend
@luke_randall, ti lodo. – Matt
Si prega di chiarire come 'assicurarsi che il rubino rbenv sia attivo'. Anche quando provo a eseguire 'gem install bundler' ottengo:' Non hai i permessi di scrittura per la directory /Library/Ruby/Gems/2.0.0. –