Subject: Re: [PATCH 1/4] Extract some utilities from git-svn to allow extracting Git::SVN.

From: Eric Wong <[email-masked]>
Date: Wed, 25 Jul 2012 21:24:18 +0000

"Michael G. Schwern" <[email-masked]> wrote:
> From: "Michael G. Schwern" <[email-masked]>
> 
> Put them in a new module called Git::SVN::Utils.  Yeah, not terribly
> original and it will be a dumping ground.  But its better than having
> them in the main git-svn program.  At least they can be documented
> and tested.
> 
> * fatal() is used by many classes.
> * Change the $can_compress lexical into a function.
> 
> This should be enough to extract Git::SVN.

Please keep Jonathan Cc:-ed, he's been very helpful with this series
(and very helpful in general :)

This series is mostly alright by me, a few minor comments inline.

> --- /dev/null
> +++ b/t/Git-SVN/00compile.t
> +
> +use Test::More tests => 1;

> +++ b/t/Git-SVN/Utils/fatal.t
> @@ -0,0 +1,34 @@
> +
> +use Test::More 'no_plan';

Didn't we agree to use done_testing()?   Perhaps (as you suggested) with
a private copy of Test::More?  It's probably easier to start using
done_testing() earlier rather than later.

> +BEGIN {
> +    # Override exit at BEGIN time before Git::SVN::Utils is loaded
> +    # so it will see our local exit later.
> +    *CORE::GLOBAL::exit = sub(;$) {
> +        return @_ ? CORE::exit($_[0]) : CORE::exit();
> +    };
> +}

For new code related to git-svn, please match the existing indentation
style (tabs) prevalent in git-svn.  Most of the Perl found in git also
uses tabs for indentation.