I've got a shell script that performs some tasks using files from a Subversion repository. I would like the Subversion repository to keep up-to-date, but right now the script runs svn up
every time which is annoying if I need to run the script several times in a row.
Since svn up
changes the last modified timestamp of the .svn
directory (even if there were no new commits), I figured that I could use that to make sure it only runs svn up
once per day or so.
I tried finding a simple way of just checking whether the .svn
directory is older than a day, but there were many seemingly overkill ways of doing it so I thought I'd ask here in case there's actually a very simple way to do it.