Changing CakePHP's tmp directory so it won't be included on SVN

Update: this solution is quite dirty, and I don't recommend it now. Check out my new post on using SVN's ignore property to ignore CakePHP's tmp directory.If you're putting your CakePHP app on version control (SVN), you'll notice that the /tmp directory is inside /app. You might want to not include /tmp on your repository as it's just a location for caches, logs, session, and other temporary stuff which is not part of your application code. Here's how to change the tmp directory of CakePHP:1. Copy /app/tmp to /tmp (copy it outside of the app directory)2. Add this code on /app/webroot/index.php after CAKE_CORE_INCLUDE_PATH is defined (line ~60). This will change the tmp directory from /app/tmp to /tmp. # define a different TMP dir outside of app define('TMP', ROOT.DS.'tmp'.DS);3. Configure the file cache path on /app/config/core.php (line ~226):Cache::config('default', array('engine' => 'File', 'path' => ROOT.DS.'tmp'.DS) );(This step is necessary for BAKE to work properly if you are using the default file cache)4. To check if it's working fine, try renaming /app/tmp to /app/xtmp and see if your app still works properly (then you can already delete that directory). If not, make sure the new tmp directory is the same as the original structure (cache, logs, sessions, tests)