After grappling with UEFI, GPT, Driver issues and what not, finally I have reasonably stable dual boot system. I used to follow this guide for setting up development environment, but it’s a bit outdated. So I decided to log the process. Here is how I set up my machine for Rails development.
Before installing the tools, I ensure that all the installed packages and the package index itself is updated.
man page of apt-get has detailed explanation for
Sublime Text has been my favorite text editor ever since I got outside the Java world and started exploring Python and Ruby. It’s lightweight, has great plugins and gives a lot of customization options. Here are my overrides for its default settings,
The easiest way of installing sublime packages is using Sublime Package Control. Just go to its site and follow the installation instructions. Once you have installed Sublime Package Control, all you have to do is press
Ctrl + Shift + P, go to
Package Control: Install Packages and select the package you want to install. One package I find very useful is GitGutter. It shows an icon in the gutter indicating if line has been inserted, modified or deleted.
The default terminal included in Ubuntu is fine for initial setup but for regular use I prefer dropdown terminals. They stay out of your way and you can conjure them when required. I started with yakuake but it has a lot of KDE dependencies, so I switched to tilda, which is really lightweight.
Git is probably the most popular version control system in the Open Source community. Most of my recent code is on GitHub. In fact, this blog itself is hosted on GitHub.
Here is my
[user] name = Nitish Parkar email = <my_github_email> [color] ui = auto [alias] co = checkout s = status b = branch hist = log --pretty=format:'%h %ad | %s%d [%an]' --branches --graph --date=short --max-count=10
Git aliases are shorthands for long git commands. Before I discovered them I almost always used to misspell status. Now it’s just
Finally, I generate ssh key and add it to GitHub as explained in this article.
I use RVM to install Ruby. Its installation is pretty straightforward. Once you have RVM, you can install multiple ruby environments and switch among them as and when required.
For RVM to work properly, you have to pass
--login flag to the shell. The way of doing this differs from terminal to terminal. This answer provides little explanation and links to appropriate resources. For tilda, set Preferences > Custom Command to
I don’t use rdoc, so by default I don’t want to download rdoc and ri info for any gems. This can be achieved by adding the following line to
gem: --no-rdoc --no-ri
I used to use RVM gemsets. But with bundler, Gemsets are not required. So I have stopped using them.
Apache and Passenger
At the end, passenger will tell you to copy paste a few lines to apache configuration file.
LoadModule passenger_module /home/nitish/.rvm/gems/ruby-2.1.1/gems/passenger-4.0.41/buildout/apache2/mod_passenger.so <IfModule mod_passenger.c> PassengerRoot /home/nitish/.rvm/gems/ruby-2.1.1/gems/passenger-4.0.41 PassengerDefaultRuby /home/nitish/.rvm/gems/ruby-2.1.1/wrappers/ruby </IfModule>
That’s it. Happy Coding! :)