ubuntu13.10 Rails环境

 1.安装RVM:

$ curl -sSL https://get.rvm.io | bash -s

 2.安装依赖:

$ rvm requirements

 3.安装ruby:

$ rvm install 2.0.0

 4.修改终端启动脚本:

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function* 
  1. 看看 ~/.bashrc 里面有没有这句,有的话直接把这个 ~/.bash_profile 删掉
  2. 没有的话,把这句添加到 ~/.bashrc 里后再把 ~/.bash_profile 删掉
  3. 调整你的终端设置,编辑 -> 配置文件首选项 -> 标题和命令 -> 以登陆 shell 方式运行命令 前面的勾去掉。关掉重开一个终端,应该就好了。

 5.使用2.0.0版本并新建gemset:

$ rvm use 2.0.0@railstutorial_rails_4_0 --create --default

 6.使用与之匹配的gem:

$ gem update --system 2.1.9

 7.安装rails:

$ gem install rails --version 4.0.3 --no-ri --no-rdoc

 8.安装git:

$ apt-get install git

 9.设置github的ssh:

$ ssh-keygen -t rsa -C "[email protected]"

   一直回车直到得到以下信息显示:The key fingerprint is:

   到~/.ssh/id_rsa.pub这个文件内到信息录入到github的个人设置下到ssh内。

 10.安装heroku:

$ wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh

 11.设置heroku的ssh:

$ heroku keys:add ~/.ssh/id_rsa.pub

猜你喜欢

转载自wudixiaotie.iteye.com/blog/2020505