New to subversion, need to find documentation on writing hooks

2012-05-20 Thread Ted Byers
I have just installed subversion on a Ubuntu VM, and trying to learn how to
administer both.  I have successfully created my first VN repository.  :-)

 

Now, I have read through the documentation a couple times, and know what
hooks are and why they're used, but I am not clear on how to write one as
the examples I have found so far are written in programming languages I
don't know (such as Python).

 

In the first project I am going to put into this repository, I am writing a
test suite based on Boost's Test library (written in C++).  What I want to
do is write a program that assesses code coverage, so that all new code has
at least one unit test, and then require that the codebase, including all
existing and new tests,  compile and execute successfully; and have a
precommit hook that prevents a commit unless this test suite program
indicates that the tests all passed.  I have read arguments that recommend
against this, claiming it can slow down commits, but then I am more
concerned about code quality, and always having a codebase, which to me
includes all tests, that compiles and runs properly than I am in the
convenience of any programmers working on the project.  I also write in Perl
and JavaScript (and not so much anymore in Java or C#), so I will want the
same requirement on all code in all the languages I routinely use.

 

Can anyone either show me how to write such a pre-commit hook, or point me
to examples that would show how to do this?

 

Thanks

 

Cheers

 

Ted

 



RE: New to subversion, need to find documentation on writing hooks

2012-05-21 Thread Ted Byers

> -Original Message-
> From: Les Mikesell [mailto:lesmikes...@gmail.com]
> Sent: May-21-12 12:58 AM
> To: Ted Byers
> Cc: users@subversion.apache.org
> Subject: Re: New to subversion, need to find documentation on writing
hooks
> 
> On Sun, May 20, 2012 at 4:16 PM, Ted Byers  wrote:
> 
> >  I have read arguments that recommend
> > against this, claiming it can slow down commits, but then I am more
> > concerned about code quality, and always having a codebase, which to
> > me includes all tests, that compiles and runs properly than I am in
> > the convenience of any programmers working on the project.
> 
> I suspect that everyone involved would be happier if you implement that in
a
> continuous integration tool like jenkins that will still check everything
(and can
> do a lot more) but does not interfere with
> commits.And use branches/tags to identify the production quality
> versions so your programmers can get some work done.
> 
> --
>   Les Mikesell
>  lesmikes...@gmail.com

Hi Les  

Thanks

I have never heard of jenkins.  What more can you tell me about it?

Cheers

Ted



RE: New to subversion, need to find documentation on writing hooks

2012-05-21 Thread Ted Byers
> -Original Message-
> From: Cooke, Mark [mailto:mark.co...@siemens.com]
> Sent: May-21-12 6:13 AM
> To: Ted Byers; 'Les Mikesell'
> Cc: users@subversion.apache.org
> Subject: RE: New to subversion, need to find documentation on writing
hooks
> 
> > -----Original Message-
> > From: Ted Byers [mailto:r.ted.by...@gmail.com]
> > Sent: 21 May 2012 11:09
> > To: 'Les Mikesell'
> > Cc: users@subversion.apache.org
> > Subject: RE: New to subversion, need to find documentation on writing
> > hooks
> >
> >
> > > -Original Message-----
> > > From: Les Mikesell [mailto:lesmikes...@gmail.com]
> > > Sent: May-21-12 12:58 AM
> > > To: Ted Byers
> > > Cc: users@subversion.apache.org
> > > Subject: Re: New to subversion, need to find documentation
> > on writing
> > hooks
> > >
> > > On Sun, May 20, 2012 at 4:16 PM, Ted Byers
> >  wrote:
> > >
> > > >  I have read arguments that recommend against this, claiming it
> > > > can slow down commits, but then
> > I am more
> > > > concerned about code quality, and always having a
> > codebase, which to
> > > > me includes all tests, that compiles and runs properly
> > than I am in
> > > > the convenience of any programmers working on the project.
> > >
> > > I suspect that everyone involved would be happier if you
> > implement that in
> > a
> > > continuous integration tool like jenkins that will still
> > check everything
> > (and can
> > > do a lot more) but does not interfere with
> > > commits.And use branches/tags to identify the production quality
> > > versions so your programmers can get some work done.
> > >
> > > --
> > >   Les Mikesell
> > >  lesmikes...@gmail.com
> >
> > Hi Les
> >
> > Thanks
> >
> > I have never heard of jenkins.  What more can you tell me about it?
> >
> > Cheers
> >
> > Ted
> >
> ...it used to be called `Hudson` if you have heard of that.
> 
> Homepage  : http://jenkins-ci.org/
> Wikipedia : http://en.wikipedia.org/wiki/Jenkins_(software)
> 

Thanks Marc

Actually, I had never heard of Hudson either; except in reference to the
famous explorer of the Canadian north, and the bay due north of Ontario, in
the eastern Canadian arctic, named for him.

Thanks for the links, though, as that gives me a starting point for
evaluating it.

Cheers

Ted