I use subversion to manage my yii website (php framework) and have separate backend and frontend webroots for my application with the following paths:
/trunk/dev/backend/www/...
/trunk/dev/frontend/www/...
Now when I update a file in the frontend, e.g.
/trunk/dev/frontend/www/css/styles.css
… I can commit changes no problem. However, for some reason, subversion thinks that the corresponding file in the backend is exactly the same as the frontend file and doesn’t treat them differently, e.g.
/trunk/dev/frontend/www/css/styles.css = /trunk/dev/backend/www/css/styles.css
… even if the backend file is vastly different. If I update subversion, no differences are identified – it’s as if they are one and the same file.
I don’t think it’s my subversion client, because I am seeing the exact same behaviour in both Coda (my normal web authoring tool which is svn savvy) and Cornerstone (my specialist svn client).
I admit I am far from a subversion expert, so don’t know if it is not good practice to manage similar application paths in one repository, but I wouldn’t have though that my situation was unique. I am scratching my head, so any ideas would be greatly appreciated.
One thing that may be significant (and I think I may have cottoned on to what is going on…) is that the styles.css file is compiled automatically from a compiled LESS file:
/trunk/dev/frontend/www/less/styles.less
/trunk/dev/backend/www/less/styles.less
Could it be that the LESS compiler (codekit) is not generating the css file in a way that subversion recognizes? BTW, I want to include my compiled css files in my repository (for reasons that probably aren’t significant to this question).
I am using subversion v1.6 if that helps. Thanks in advance for any help 🙂
EDIT: I’ve updated the paths to show how they relate to my repository (trunk). My working copy pulls from ‘dev’ which is a subfolder under trunk. I’ve tried to reproduce this problem to describe the symptoms better, but of course, now it works without a problem (Murphy…). I don’t want to waste anybody’s time on this, so will come back if the problem reoccurs and I can give more information.
Think I know what happened – found out that my ‘backend/www/css/’ folder (generated by less) was somehow ‘switched’ and was pointing to the ‘frontend/www/css’ folder. I’m guessing I did this somehow in my svn client (Coda or Cornerstone) without being aware of it, hence the strange symptoms where updates were not being reflected as I suspected.
Have removed the switching and everything is back to normal (phew!). Thank for those who took the time to look at this, I know it was an odd one!