[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Commit Hook Error

From: Jake Stone <jake.the.stone_at_gmail.com>
Date: Sat, 05 Sep 2009 05:01:45 -0500

Hello all! I am working on some simple commit hooks for my repository,
and I ran into a slight issue.

I am using some easy batch commands to grab information from the svnlook
tool so I can send emails about the commit, but "svnlook author" is
being stubborn. Running from the command line, svnlook author gives the
correct committer's username, yet this code:

FOR /F "tokens=*" %%i in ('%SVNDIR%\svnlook author -r "%REV%"
"%REPOS%"') do SET TOOLOUTPUT=%%i
SET AUTHOR=%TOOLOUTPUT%

FOR /F "tokens=*" %%i in ('%SVNDIR%\svnlook date -r "%REV%" "%REPOS%"')
do SET TOOLOUTPUT=%%i
SET DATE=%TOOLOUTPUT%

SET SUBJECT="%REPOSNAME% updated by %AUTHOR% on %DATE%"

Will produce a subject of "Repository updated by on Sat 09/05/2009"
This is obviously rather frustrating, since the exact same command works
on date but not author. I could just tell the commands to append their
information to a file, but then it'd be harder to make email subject
lines, etc like the one above.

Any ideas?

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2391264

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-09-05 12:02:10 CEST

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.