Author Topic: Tip: Keeping up-to-date with latest NGUI with SVN  (Read 1399 times)

AeornFlippout

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 46
    • View Profile
Tip: Keeping up-to-date with latest NGUI with SVN
« on: January 31, 2014, 11:37:41 AM »
So I'm always asking for help here, I thought I'd give something back :)

We use subversion for our project and don't have git access to NGUI.  I also have several local modifications to NGUI, which has made keeping up-to-date a bit of a pain.

Here's a method for updating that seems to work pretty well so far. This will probably seem pretty basic to any source-control gurus.

First, Create a separate project called "NGUI_Trunk", and import whatever version of NGUI you're currently using into it. Skip the "Examples" directory and anything else that's not in your project. Check this into svn.

Now when it's time to upgrade NGUI - here's what you'll do:
1. Go through the upgrade process as prescribed for NGUI.
2. Browse to the NGUI directory, and use this on the commandline:

"svn diff > mychanges.diff"

This will create a patch file that consists of all the changes made in NGUI since your last update.

3. Copy this .diff file to your project's NGUI folder, browse there, and use:

"patch -p0 -i ./mychanges.diff"

This will apply all the changes to your local project.

4. Review the changes and check in both projects.

I don't know if this is the "right" way to do this, but it's a lot less painful than manually re-entering your local changes after an update.