牌語備忘録 -pygo

あくまでもメモです。なるべくオフィシャルの情報を参照してください。

牌語備忘録 -pygo

RVM で Ruby1.9.3 がうまく動いてくれないので、『rbenv』に乗り換えてみた

Rails を作った HDD のいる会社 37signals の人か作ったらしい『rbenv』をつかってみる
(環境: MacOSX10.7.4,)

Download: rbenv

$ cd
$ git clone git://github.com/sstephenson/rbenv.git .rbenv

Config: bash_profile or bashrc

export PATH="$HOME/.rbenv/bin:$PATH"
eval "$(rbenv init -)"

Download & install: ruby-build

$ git clone git://github.com/sstephenson/ruby-build.git
$ cd ruby-build
$ sudo install.sh

Install: ruby

修正: 2012-07-22
openssl と readline をインストールしてから
ruby をインストール。

Macports でインストールした場合

$ cd
$ sudo port install openssl
$ sudo port install readline
$ CONFIGURE_OPTS="--with-openssl-dir=/opt/local --with-readline-dir=/opt/local" rbenv install 1.9.3-p194
$ sudo rbenv rehash

$ rbenv install 1.9.3-p194
Downloading http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz...
$ sudo rbenv rehash

rbenv rehash 必要かも? rbenv rehash 必要

Select: version

$ rbenv global
system
$ rbenv global 1.9.3-p194
$ rbenv global
1.9.3-p194
$ rbenv version
1.9.3-p194 (set by /Users/username/.rbenv/version)
$ rbenv versions
* 1.9.3-p194 (set by /Users/username/.rbenv/version)
ruby -v
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]

Help:

$ rbenv -h
rbenv 0.3.0
usage: rbenv <command> [<args>]

Some useful rbenv commands are:
   commands      List all rbenv commands
   rehash        Rehash rbenv shims (run this after installing binaries)
   global        Set or show the global Ruby version
   local         Set or show the local directory-specific Ruby version
   shell         Set or show the shell-specific Ruby version
   version       Show the current Ruby version
   versions      List all Ruby versions known by rbenv
   which         Show the full path for the given Ruby command
   whence        List all Ruby versions with the given command

See 'rbenv help <command>' for information on a specific command.
For full documentation, see: https://github.com/sstephenson/rbenv#readme