Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Trac: Users

SVN Post Commit Email on Windows SBS with tracd

 

 

Trac users RSS feed   Index | Next | Previous | View Threaded


wbranderson at gmail

May 8, 2008, 1:11 PM

Post #1 of 5 (161 views)
Permalink
SVN Post Commit Email on Windows SBS with tracd

I have looked through several of the SVN Post Commit related threads
on the group site here and still have a few questions about setting up
Trac to send a post-commit email (including changset number, who made
the change, a list of modified files, and the log entry contents) out
to a group of individuals upon changeset committal.

I am running trac 0.10.4, standalone tracd, on a Windows SBS system.

1) Several of the posts make reference to a file "trac-post-commit-
hook.py". I do not have that file on my system. Should I? And if
not, where do I obtain a copy?

2) It seems that setting up the post-commit system is a bit tricky on
Windows. Is anyone aware of a complete tutorial on how to set up the
post-commit on a Windows box?

I would prefer to not use Perl, since I do not have it installed on
the server. I can install it, but since its not installed already,
I'd prefer to keep things simpler if at all possible.

Thanks in advance for your help!

Brett
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To post to this group, send email to trac-users[at]googlegroups.com
To unsubscribe from this group, send email to trac-users-unsubscribe[at]googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---


manu.blot at gmail

May 8, 2008, 1:43 PM

Post #2 of 5 (154 views)
Permalink
Re: SVN Post Commit Email on Windows SBS with tracd [In reply to]

> I have looked through several of the SVN Post Commit related threads
> on the group site here and still have a few questions about setting up
> Trac to send a post-commit email

> 1) Several of the posts make reference to a file "trac-post-commit-
> hook.py". I do not have that file on my system. Should I? And if
> not, where do I obtain a copy?

I'm surprised you never found a reference to the '/contrib' directory
(see Trac source code). An exemple of such as script is available
there
http://trac.edgewall.org/browser/trunk/contrib
or a more specialized one:
http://trac-hacks.org/browser/revtreeplugin/0.11/hooks

> 2) It seems that setting up the post-commit system is a bit tricky on
> Windows. Is anyone aware of a complete tutorial on how to set up the
> post-commit on a Windows box?

See the latest URL: there are some wrapper scripts for Unix shell and
batch files. You'll obviously need to tweak the paths they use, but
that's a pretty
straightforward operation.

> I would prefer to not use Perl, since I do not have it installed on
> the server. I can install it, but since its not installed already,
> I'd prefer to keep things simpler if at all possible.

Both those scripts are written in Python - as it's far more easier to
invoke Trac API from Python ;-)

Cheers,
Manu

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To post to this group, send email to trac-users[at]googlegroups.com
To unsubscribe from this group, send email to trac-users-unsubscribe[at]googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---


wbranderson at gmail

May 9, 2008, 12:19 PM

Post #3 of 5 (143 views)
Permalink
Re: SVN Post Commit Email on Windows SBS with tracd [In reply to]

Manu--

Thank you for yuor help! I am not much of a Python programmer ... do
you know of any resource I can use to have a post-commit hook to
merely send a notification email out to a group of people with the
changeset number, who committed the changeset, a list of the files
changed, and the contents of the log entry?

I really don't need the features to close tickets and add changeset
logs to tickets at this current point in time.

Of course, if this is independent of Trac (which I get the sense it
might be) ... please let me know and I will look elsewhere.


Thanks again for your help!

Brett

On May 8, 4:43 pm, "Emmanuel Blot" <manu.b...@gmail.com> wrote:
> > I have looked through several of the SVN Post Commit related threads
> > on the group site here and still have a few questions about setting up
> > Trac to send a post-commit email
> > 1) Several of the posts make reference to a file "trac-post-commit-
> > hook.py". I do not have that file on my system. Should I? And if
> > not, where do I obtain a copy?
>
> I'm surprised you never found a reference to the '/contrib' directory
> (see Trac source code). An exemple of such as script is available
> there
> http://trac.edgewall.org/browser/trunk/contrib
> or a more specialized one:
> http://trac-hacks.org/browser/revtreeplugin/0.11/hooks
>
> > 2) It seems that setting up the post-commit system is a bit tricky on
> > Windows. Is anyone aware of a complete tutorial on how to set up the
> > post-commit on a Windows box?
>
> See the latest URL: there are some wrapper scripts for Unix shell and
> batch files. You'll obviously need to tweak the paths they use, but
> that's a pretty
> straightforward operation.
>
> > I would prefer to not use Perl, since I do not have it installed on
> > the server. I can install it, but since its not installed already,
> > I'd prefer to keep things simpler if at all possible.
>
> Both those scripts are written in Python - as it's far more easier to
> invoke Trac API from Python ;-)
>
> Cheers,
> Manu
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To post to this group, send email to trac-users[at]googlegroups.com
To unsubscribe from this group, send email to trac-users-unsubscribe[at]googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---


yoheeb at gmail

May 9, 2008, 12:45 PM

Post #4 of 5 (143 views)
Permalink
Re: SVN Post Commit Email on Windows SBS with tracd [In reply to]

On May 9, 2:19 pm, Brett <wbrander...@gmail.com> wrote:
> Manu--
>
> Thank you for yuor help! I am not much of a Python programmer ... do
> you know of any resource I can use to have a post-commit hook to
> merely send a notification email out to a group of people with the
> changeset number, who committed the changeset, a list of the files
> changed, and the contents of the log entry?
>
> I really don't need the features to close tickets and add changeset
> logs to tickets at this current point in time.
>
> Of course, if this is independent of Trac (which I get the sense it
> might be) ... please let me know and I will look elsewhere.
>
> Thanks again for your help!
>
> Brett
>
<snip>

I think you have 2 avenues here. You can do it purely as a subversion
post-commit-hook (helps if you have a pre-commit-hook to enforce all
the things you are asking for), or you can have a subversion post-
commit-hook, which calls a trac-post-commit-hook, which updates the
tickets, and configure trac to notify people of changes to the
ticket. (possibly customizing this to include the information if they
don't want to navigate to the web page to READ it (say, one of the
recipients is another script :D)

Anyway, trac can be configured to notify people of a change to the
ticket, and subversion can be configured to update a ticket in trac,
so this is possible the simplest route if you ultimately want to do
more with trac and the commit. The shortest immediate route, is
likely to have a Subversion post-commit-hook script, which fires off
the email with the information you want, which all comes from
subversion, maybe via smtp for example. Keep in mind all the calls to
Subversion you make to collect the information, would still be called
whether or not you do anything via trac. Now, sending the actual
email can be a pain either way on windows, depending on your setup :D

ok, to summarize:

all the information can get pulled from Subversion as a Subversion
post commit hook.
It can then either be sent to trac, to update a/several ticket(s) or
can be directly mailed to the recipients. (Trac can Also pull it from
subversion, but that a symantic)
If sent to Trac, Trac can be configured to update the ticket(s),
separately, it can additionally be configured to notify recipients on
change to a ticket.

Finally, I am a trac noob, so I'd love to hear the other options (I am
sure there is a webdav route, maybe a DB trigger route...etc.)

:D

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To post to this group, send email to trac-users[at]googlegroups.com
To unsubscribe from this group, send email to trac-users-unsubscribe[at]googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---


wbranderson at gmail

May 9, 2008, 1:39 PM

Post #5 of 5 (144 views)
Permalink
Re: SVN Post Commit Email on Windows SBS with tracd [In reply to]

I downloaded svn-notify (readily available on the net for *nix or
windows) a little while ago and am trying to configure it now. It
comes with basic pre- and post-commit hooks which I am now customizing
to fit my needs, and looks like it will provide all of the
functionality I am requiring as of now. I may go with more Trac
integration at a later date, but for now all I desire is the email
notification.

Brett

On May 9, 3:45 pm, yoh...@gmail.com wrote:
> On May 9, 2:19 pm, Brett <wbrander...@gmail.com> wrote:
>
> > Manu--
>
> > Thank you for yuor help! I am not much of a Python programmer ... do
> > you know of any resource I can use to have a post-commit hook to
> > merely send a notification email out to a group of people with the
> > changeset number, who committed the changeset, a list of the files
> > changed, and the contents of the log entry?
>
> > I really don't need the features to close tickets and add changeset
> > logs to tickets at this current point in time.
>
> > Of course, if this is independent of Trac (which I get the sense it
> > might be) ... please let me know and I will look elsewhere.
>
> > Thanks again for your help!
>
> > Brett
>
> <snip>
>
> I think you have 2 avenues here. You can do it purely as a subversion
> post-commit-hook (helps if you have a pre-commit-hook to enforce all
> the things you are asking for), or you can have a subversion post-
> commit-hook, which calls a trac-post-commit-hook, which updates the
> tickets, and configure trac to notify people of changes to the
> ticket. (possibly customizing this to include the information if they
> don't want to navigate to the web page to READ it (say, one of the
> recipients is another script :D)
>
> Anyway, trac can be configured to notify people of a change to the
> ticket, and subversion can be configured to update a ticket in trac,
> so this is possible the simplest route if you ultimately want to do
> more with trac and the commit. The shortest immediate route, is
> likely to have a Subversion post-commit-hook script, which fires off
> the email with the information you want, which all comes from
> subversion, maybe via smtp for example. Keep in mind all the calls to
> Subversion you make to collect the information, would still be called
> whether or not you do anything via trac. Now, sending the actual
> email can be a pain either way on windows, depending on your setup :D
>
> ok, to summarize:
>
> all the information can get pulled from Subversion as a Subversion
> post commit hook.
> It can then either be sent to trac, to update a/several ticket(s) or
> can be directly mailed to the recipients. (Trac can Also pull it from
> subversion, but that a symantic)
> If sent to Trac, Trac can be configured to update the ticket(s),
> separately, it can additionally be configured to notify recipients on
> change to a ticket.
>
> Finally, I am a trac noob, so I'd love to hear the other options (I am
> sure there is a webdav route, maybe a DB trigger route...etc.)
>
> :D
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To post to this group, send email to trac-users[at]googlegroups.com
To unsubscribe from this group, send email to trac-users-unsubscribe[at]googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Trac users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.