One of the coolest things about Git is how easy it makes working with branches. Rails has been playing catch up with Git’s distributed methodologies and recently took a nice step forward. Previously you could only useĀ ./script/plugin install to install from the master branch of a Github repository. Now you can specify the branch name when installing the plugin
./script/plugin install git://github.com/technoweenie/restful-authentication.git -r modular
This will install the modular branch of the Restful Authentication plugin. Pretty cool, huh?
At the time of writing this Rails 2.2 has not been released. If you are using Rails 2.1.0 or 2.1.1 you will need to upgrade to Edge Rails for this to work. Otherwise you will have to wait for 2.2 to be released.
Tags: Git, github, plugins, Rails
This is just for Github you know. It works with any git repo.
Is the fact that you used the modular branch kept in your project somewhere, so when you come back to it a couple of monnths later, you can easily find out that RA isn’t working as expected cos your using modular instead of master?
Also is there any way to update the plugin correctly?
I’m completely new to Rails (and new to programming) and am in the process of developing a social network. I am trying to install the restful authentication plug-in with no luck. I’m using rails 2.1.1 and Windows XP. Where do I download this plug-in from? and once downloaded, what file do I put it in? (e.g., should I include in the InstantRails folder?)
if the above doesn’t work, try:
git clone git://github.com/foo/kung-foo.git vendor/plugins/kung-foo && rm -rf vendor/plugins/kung-foo/.git
On Windows you need to ensure you have git installed via cygwin. Then in cygwin you can use the command documented above.