[Ubuntu] 安裝 compass

這裡有個快速的參考

https://gist.github.com/stephou0104/233b5c99884f1d8c8b8b

  1. 先把需要的周邊套件都先裝一裝
    sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties

    sudo apt-get install libgdbm-dev libncurses5-dev automake libtool bison libffi-dev
     
  2. 把 rvm 的環境架起來,注意的是第一步
    gpg --keyserver hkp://keys.gnupg.net --recv-keys D39DC0E3
    curl -L https://get.rvm.io | bash -s stable
    source ~/.rvm/scripts/rvm
    echo "source ~/.rvm/scripts/rvm" >> ~/.bashrc
     
  3. 接著就可以開始安裝ruby了
    rvm install 2.1.2
    rvm use 2.1.2 --default
     
  4. ruby裝完,就能用 gem 來安裝 compass了
    gem install compass