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

Re: Post-Commit and Sending Email For Beginners

From: Karl Robillard <karlr_at_vision-scape.com>
Date: 2004-04-26 21:12:25 CEST

On Thursday 22 April 2004 06:56, Brian Beaudet wrote:
> I'm using Subversion on Windows 2K using Apache as the server. Could
> someone please give me some pointers on how to send emails out after a
> successful commit? I'm new at server administration and Apache so be
> easy with my delicate brain. Thanks.
>
>
>
> Brian M. Beaudet
>
> Director, Research & Development
>
> EfficiencyLab, LLC
>
> www.efficiencylab.com

Here's the REBOL script I use for email notification:

[karl@linux2 hooks]$ cat hooks/post-commit
#!/bin/sh
svn log -v -r "HEAD" http://localhost/bkg/trunk/code >/tmp/svn_log
rebol -w /home/bkg/svn/hooks/svn_update.r /tmp/svn_log

[karl@linux2 hooks]$ cat hooks/svn_update.r
REBOL [
  Purpose: {Mail subversion log specified on command line}
]

set-net [your-address@your-domain.com mail.your-mail-server.com]
system/schemes/smtp/user: "your-login"
system/schemes/smtp/pass: "your-password"

log: read to-file system/script/args
text: "Automated Subversion Report^/^/"
append text log

send/only [
    user1@your-domain.com
    user2@your-domain.com
    user3@your-domain.com
]
text

;eof

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Mon Apr 26 21:13:00 2004

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.