How to update the ruby version on heroku ?

When we want to update the ruby version of our heroku hosted ruby website, heroku eventually send a notification for it when there is need to update the ruby version of the heroku app.

This post shows how to update the ruby version on heroku,

These are the prerequisites on your windows machine before begin the update process

  1. Node.js
  2. Ruby 2.2.4
  3. Heroku toolbelt
  4. Git 1.8.6 >

That’s it.

Then you have to login to heroku account using this command

$ heroku login

 

 

 

Then you have to clone the site folder using git.

 

 

 

After that you have to move to the cloned site folder

 

If you want to update the bundler version of your site issue the following command inside the folder

 

 

Then configure the heroku build packs if your heroku ruby project issuing following command

 

 

 

To lock the bundler version if you have encountered an error we must have to lock it to specific version issuing following command in the terminal

heroku-lock-bundler-version

After that open the gem file using your favorite text editor “notepad++” or “sublime text”

Then you have to add the following line to your ruby gem file inside your cloned folder.

You must add this line after the “source ‘https: //rubygems.org’ ” line

ruby “2.2.4”

sublime_edit_gem_file

https://devcenter.heroku.com/articles/ruby-versions

Then save the gem file, that’s all

There is no need to change the other lines of this file

Then issue the following commands one by one to push the source repository to the heroku.

 

 

 

 

That’s all after that you’ll see following successful progress screen

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

This is the final result after updating the ruby version “2.0.0” to “2.2.4”

final

Thats all . Have a nice day 🙂 !

 

How to update the ruby version on heroku ?

Finally upgraded to ROR 5 !

I’ve experimenting web developing on Ruby on Rails as a hobby. Last few days I’ve work with ruby 1.9.3 and ROR 3.2.x and felt that I must move to ruby version 2.x.x and  ROR 5 because ROR community fastly moved to new ROR version and old version is being deprecated. So here I’ve show you what is on it. Before that below screenshot shows that how the old ROR 4 start page looks like . Because I loved that very much :-).

RUBY_ON_MY_MACHINE - Copy

Let’s rock on!

Here firstly I’ve fully removed ruby 1.8.7 and ROR 4 from my machine. After that I’ve installed ruby 2.2.4 and ROR 5.0.0.1

After that in the terminal I’ve issued the following command

>rails new first_app

So it creates a new rails app

Untitled

Oh looo..ong Screenshot 😀

After that move to that newly created rails app folder and issue the following command in the windows or linux terminal.

first_app>rails server

ROR2

After that type the following url in your web browser

http://localhost:3000/

Now you can see the browser screen as below.

ROR1

Yay 😀 it rocks !

The main difference is the welcome page is been changed and it’s clean and simple .Also the web server moved to “WEBRICK” to “PUMA”.

Thats it !

 

Finally upgraded to ROR 5 !