Archive for the ‘Ruby on Rails’ Category

Adding files to Subversion

Tuesday, November 21st, 2006

I picked up this tip when I was beginning to work with Ruby on Rails and Subversion. I added the following alias to my .profile file

alias svnaddall=’svn status | grep “^\?” | awk “{print \$2}” | xargs svn add’


This command takes all files in the present directory and flags them to be added in the next commit. This saves adding each of the files one-by-one. You don’t just have to use the command for Rails either- use it for everything. I do!

Technorati Tags:
, ,

Capistrano Deployment on Dreamhost

Tuesday, June 27th, 2006

After much reading about the joys of capistrano, I decided to test it! I spent ages reading tutorials- and the excellent guide on the ruby on rails website (link). But I still couldn’t deploy my small test apps. I had some great pointers, but basically the gist is if you haven’t already logged into the remote servers by ssh and verified its fingerprint then capistrano deployment fails. Since you cannot ssh into your dreamhost database server, the trick to use is to list your web, app and database servers as the domain that you would like to host from; i.e. ruby.mygreenjar.com. Since all the appropriate database servers should be set in database.yml everything should execute perfectly.