Re: [PATCH/RFC] git-svn: remove auto_abbrev (Getopt::Long option)
- From
- Eric Wong <normalperson@yhbt.net>
- Date
- Aug 17, 2011, 01:02 UTC
- Message-ID
- <20110817010210.GA1189@dcvr.yhbt.net>
- In-Reply-To
- <4E46DF9C.8040900@gmail.com>
Piotr Krukowiecki <piotr.krukowiecki@gmail.com> wrote:
Show 8 quoted lines
> RFC because this changes user interface (no option abbreviation), > but I know no other good way to fix the --author problem. > > The --author option would be useful, because I usually use > git svn log --oneline > and paste the changes with svn revision numbers to bugzilla etc. > > All tests pass with this change.
How about minimizing the impact and potential breakage with this?
(I'm not sure if "blame" benefits/hurts from this, I almost never use any form of it)
diff --git a/git-svn.perl b/git-svn.perl index 96f373f..ba382eb 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -298,6 +298,9 @@ my %opts = %{$cmd{$cmd}->[2]} if (defined $cmd); read_git_config(\%opts); if ($cmd && ($cmd eq 'log' || $cmd eq 'blame')) { Getopt::Long::Configure('pass_through'); + if ($cmd eq 'log') { + Getopt::Long::Configure('no_auto_abbrev'); + } } my $rv = GetOptions(%opts, 'help|H|h' => \$_help, 'version|V' => \$_version, 'minimize-connections' => \$Git::SVN::Migration::_minimize,
-- Eric Wong