Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maintaining file permissions across SVN updates?

I have a series of python scripts with execute permissions in Linux. They are stored in SVN.

If I then run svn up to update them, the overwritten files are back to 644 - ie no execute permissions for anyone.

Yes I could just script it to chmod +x * afterwards, but surely there's a way to store permissions in SVN or to maintain them when you update?

Any suggestions appreciated.

like image 954
Mark Mayo Avatar asked May 27 '10 10:05

Mark Mayo


People also ask

Does SVN store file permissions?

Graham, svn doesn't store permissions. Your only option is to wrap your call to svn in a script. The script should call svn with its arguments, then set the permissions afterward. Depending on your environment, you might need to call your script svn and tweak your PATH to ensure it gets called.


1 Answers

You need to set the svn:executable property on the file.

svn propset svn:executable true  <filename> 
like image 95
Daniel Roseman Avatar answered Sep 17 '22 15:09

Daniel Roseman