A Weblog written, styled and hacked by Joel Moss
Update: The Github repository I created now has an untouched clone of the CakePHP 1.2 SVN branch as the master. I then created a branch of this called ‘pimped’, which contains my own custom code. This means that you can choose to use the official Cake core, or my pimped copy. I’ll try to write a little more about my pimped branch in a future post.
For the last few months, I’ve been developing an application which I hope to release to the unsuspecting public very soon. So I wanted to get it on my server and tested remotely, which I promptly did by checking out a copy from my SVN repository. I also did the same for the Cake core, by checking out https://svn.cakephp.org/repo/branches/1.2.x.x/cake.
Great, all worked fine… until I spotted loads of errors in the app. I then remembered that I made some local changes to the Cake core. I know, I know, it’s a cardinal sin. But I really needed these changes for this app, and it was doing nobody any harm, as they stayed on my local machine. But now, I also needed them on my remote copy on the server, but want to be able to ’svn up’ the cake core, whenever there are updates.
So I figured the best way would actually be to use a different SCM just for this purpose. I’d played with Git a little, and have been really impressed at Github. So I created a public repo at Github, and proceeded to create a clone of the Cake SVN repo, which I then pushed to the public repo at Github. I then applied my custom changes, and now we have a mirror of the CakePHP 1.2 branch at https://github.com/joelmoss/cakephp/tree.
I can now clone the new git repo on my remote server, and I have a copy of CakePHP with all my custom changes, which I can update as and when I need to. This is all assuming of course, that I regulalry update the repo from the Cake SVN repo.
So things have actually turned out quite well. Please feel free to push and pull to/from the new git repo, and let me know your thoughts.
My name is Joel Moss, a web developer and all round nice guy, living in Manchester, England. I am currently working full time for ShermansTravel.com, but I fill whatever spare time I have with lots of good and wholesome "stuff"! Like developing my own ideas; such as Tooum, contributing to the excellent CakePHP framework, and doing more work for ShermansTravel.
So this is my blog - my soap box! Here I attempt to share my likes, my dislikes, and my opinions. As well as providing some occasional respite from the daily crap we all endure. Enjoy ;)
Hey, if you want to reach me, i'm available via email:joel[at]developwithstyle[dot]com, and AIM:joelkmoss.
josh
April 29th, 2009 at 3:35 am
I’d really like to figure out a way to clone the official cake core git repo and merge it with my own in a method that would make ‘updating’ my project(s) with the latest cakephp core quick and painless. As it stands, upgrading is rather manual. Any tips/ideas?
Joel
April 29th, 2009 at 7:09 am
Simply fork the cake repo on the Chaw, and then modify your forked copy. Then all you have to do when the core is updated, is to merge it into your fork.