First, update to macports 1.8.2.
sudo port install ruby
I’m going to get 1.8.7 p249
- p249 “has marshaling bugs that crash Rails 3.0.0“
- Get RVM to help manage the versions.
bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head ) if [[ -s "$HOME/.rvm/scripts/rvm" ]] ; then source "$HOME/.rvm/scripts/rvm" ; fi source ~/.rvm/scripts/rvm rvm notes
Add to .profile:
for profile in .bash_profile .bashrc ; do echo 'if [[ -s "$HOME/.rvm/scripts/rvm" ]] ; then source "$HOME/.rvm/scripts/rvm" ; fi' >> $HOME/$profile done
Is this necessary? Should it be in .bash_profile? (Probably not as it references .bash_profile). I’m still fairly new to UNIX and so don’t know my profile consequences off by heart.
I’m preferring Rails 3 as:
- It’s definitely the way of the future.
- There’s quite a few new APIs — meaning old ones will be abandoned. Rails doesn’t sit still.
- The API appears to be improved all the way around; it’s more fun to use.
- It should be stable & released by the time I’m ready to launch.
But which ruby version should I be using? All seem to have potential for issues. I’ll run 1.8.7@249 and see if it works.
RubyGems update, attempt 1:
gem update --system Updating RubyGems /opt/local/lib/ruby/site_ruby/1.8/rubygems/spec_fetcher.rb:245: [BUG] Segmentation fault ruby 1.8.7 (2010-01-10 patchlevel 249) [i686-darwin9] Abort trap
I didn’t sudo, and it gave me a segfault instead of a real error 🙁
Attempt #2, this time with sudo:
sudo gem update --system Password: Updating RubyGems Updating rubygems-update Successfully installed rubygems-update-1.3.7 Updating RubyGems to 1.3.7 Installing RubyGems 1.3.7 RubyGems 1.3.7 installed Successfully uninstalled gemcutter-0.1.6 Successfully uninstalled gemcutter-0.3.0 ...
gem install rails --pre ... Installing ri documentation for rails-3.0.0.beta3... File not found: lib
I’m going to try Heroku for deployment/hosting.
First, I need Bundler:
sudo gem install bundler /opt/local/lib/ruby/site_ruby/1.8/rubygems/spec_fetcher.rb:254: warning: getc is obsolete; use STDIN.getc instead
I hate warnings.
Next is the Heroku gem:
sudo gem install heroku
Time to read up on the Heroku quickstart.