setup Rails ubuntu 14.04 LTS

what I tried

ubuntu 14.04 LTS install / and update
—after that
open terminal ctl+alt T
install git - at ubuntu software center

(need git to install rbenv)

$ git --version
git version 1.9.1

install rbenv

$ git clone ~/.rbenv
$ echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
$ echo 'eval "$(rbenv init -)"' >> ~/.bashrc
$ exec $SHELL 
$ type rbenv
"rbenv is a function"

$ git clone ~/.rbenv/plugins/ruby-build
$ rbenv install -list

install three of ruby versions

$ rbenv install 1.9.3-p547
$ rbenv install 2.0.0-p481
$ rbenv install 2.1.2

rbenv install 2.0.0-p451 didn’t work so tried

$ rbenv global 1.9.3-p545
$ ruby -v
ruby 1.9.3p545

and then tried again

$ rbenv install 2.0.0-p451

didn’t work so read error message “…The Ruby openssl extension was not compiled. Missing the OpenSSL lib?” a-ha!

so I tried this (I forgot about this..)

$ sudo apt-get -y install build-essential zlib1g-dev libreadline-dev libssl-dev libcurl4-openssl-dev libsqlite3-dev 


git-core sqlite3 curl libyaml-dev libxml2-dev libxslt1-dev python-software-properties

(I didn’t do this but says do)
and then tried again

$ rbenv install 2.0.0-p451

didn’t work. this time simply exit and open terminal and then try. didn’t work. go home and let’s try again.

did I update?

$ sudo apt-get update

and try again didn’t work. install 2.1.2 first and worked!

$ rbenv install 2.1.2

and then.. found out there’s stable version 2.0.0-p481. so tried

$ rbenv global 2.1.2
$ rbenv install 2.0.0-p481

and it worked!

$ rbenv uninstall 1.9.3-p545
$ rbenv install 1.9.3-p547

not it seems all done in installing ruby versions. Now I installed gems.

$ gem install sqlite3
$ gem install bundler
$ sudo apt-get install nodejs
$ nodejs -v

(need node.js to do “rails server”)

$ gem install rails --no-ri --no-rdoc
$ rbenv rehash
$ rails new testapp
$ cd testapp
$ rails server

(and lookup localhost:3000 in the browser)

download sublime text from ‘’ and extract on home, and set the shortcut.

$ sudo mv 'Sublime Text 2' /opt/Sublime\ Text\ 2
$ sudo ln -s '/opt/Sublime Text 2/sublime_text' /usr/bin/subl
$ subl .

I think it worked. just going to open another terminal window after opening.


Now read this

ionic & cordova setup

install ionic # sudo npm install -g ionic cordova sudo npm install -g ios-sim npm dependency.. start a project # ionic start myApp blank ionic start myApp tabs ionic start myApp sidemenu cd myApp run # ionic platform add ios ionic build... Continue →