Upgrade Your Drupal Skills

We trained 1,000+ Drupal Developers over the last decade.

See Advanced Courses NAH, I know Enough

CVS: Patch capabilities on your windows machine

Parent Feed: 

So, I really wanted to try and get into the world of testing patches in order to help get Drupal 6 to the next beta stage but I was in a world of unknown. The root of the problem was the procedure that was needed in order to apply a patch to a file or group of files. See, I am using a windows machine and by default the Linux bash commands are not available. The patch procedures were showing “patch filename < patchname” and this was not going to work on my machine.

Luckily I found the http://drupal.org/node/60179 which talked about just this problem. I read through this page and decided to try out the Cygwin solution. This basically emulates a Linux environment on my window machine. This will be my solution until I am able to gather enough cash for my mac book pro! I went to the http://www.cygwin.com/ website and clicked on the install or update now link in order to put the setup.exe file on my desktop.

I followed the steps on the http://drupal.org/node/32875 node and everything was pretty easy. The gist of what happened is that on the root of my windows there is now a cygwin folder that houses a Linux directory structure. The install created a shortcut to a “terminal window” that accesses this directory structure in a Linux emulated terminal window. I did a cvs checkout of the drupal head into the c:/cygwin/var/www/drupal using Tortoise CVS (http://www.tortoisecvs.org/) and now I have a fresh copy of Drupal Head version.

For fun I edited the UPGRADE.txt file and then used the right click tortoiseCVS menu to create a cvs patch file in the same directory. I then un-did the UPGRADE.txt changes to get the file back to its original state. Remember, I have my changes in my patch file. Then I used the Cygwin terminal shortcut to traverse to /var/www/drupal and was able to run the linux patch command of “patch UPGRADE.txt < UPGRADE.txt.patch”. Worked like a charm! Now I am going to test some patches and see if I can help out the Drupal cause, just a bit more.

Author: 
RSS Tags: 
Original Post: 

About Drupal Sun

Drupal Sun is an Evolving Web project. It allows you to:

  • Do full-text search on all the articles in Drupal Planet (thanks to Apache Solr)
  • Facet based on tags, author, or feed
  • Flip through articles quickly (with j/k or arrow keys) to find what you're interested in
  • View the entire article text inline, or in the context of the site where it was created

See the blog post at Evolving Web

Evolving Web