Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm hosting svn server for my developers. From server I see all configured dirs with svn repos. I want to get last modification date on all of them(obout 30 different projects). I don't want to connect to all of them make checkout and then with svn command on each check last modification. I want use only bash to extract that info but have no idea how and even is it possible in that way.

EDIT1: it looks like this that a have for example 10 project in different repos on the same server (no branches)... all project sits in one directory configured as different svn repos:

/svn_repos/project1

/svn_repos/project2

/svn_repos/project3

...

/svn_repos/project10
share|improve this question

1 Answer 1

up vote 1 down vote accepted
svnlook tree --full-paths "$REPO" | grep '/branches/[^/]*/$' | \
while read branch ; do
    svnlook history -l 1 "$REPO" "$branch"
done | while read revision path ; do
    # Input looks like the following, in a loop...
    #
    # REVISION   PATH
    # --------   ----
    #       20   /path/to/branch
    case "$revision" in
      REVISION|--------) : ;;  # Skip headers
      *) echo "$path" `svnlook date -r "$revision" "$REPO"`
         ;;
    esac
done
share|improve this answer
    
Nice script but it does not work in my case...there is no branches in any of my repos ... –  B14D3 Aug 26 '13 at 8:44
1  
Then it's even easier. Just use svnlook date "$REPO". –  200_success Aug 26 '13 at 15:19
    
Yup that last one is what I need! THX –  B14D3 Aug 27 '13 at 6:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.