diff options
author | brian m. carlson <sandals@crustytoothpaste.net> | 2020-06-22 18:04:12 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-06-22 11:21:07 -0700 |
commit | 9ab33150a0d14089d0496dd8354d4a969e849571 (patch) | |
tree | 449f035f6f30575a57d5c84c2d03d3588058eed2 /perl/Git/SVN/Editor.pm | |
parent | t/lib-git-svn: make hash size independent (diff) | |
download | tgif-9ab33150a0d14089d0496dd8354d4a969e849571.tar.xz |
perl: create and switch variables for hash constants
git-svn has several variables for SHA-1 constants, including short hash
values and full length hash values. Since these are no longer SHA-1
specific, let's start them with "oid" instead of "sha1". Add a
constant, oid_length, which is the length of the hash algorithm in use
in hex. We use the hex version because overwhelmingly that's what's
used by git-svn.
We don't currently set oid_length based on the repository algorithm, but
we will in a future commit.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Acked-by: Eric Wong <e@80x24.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'perl/Git/SVN/Editor.pm')
-rw-r--r-- | perl/Git/SVN/Editor.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/perl/Git/SVN/Editor.pm b/perl/Git/SVN/Editor.pm index 0df16ed726..70b6d78cd9 100644 --- a/perl/Git/SVN/Editor.pm +++ b/perl/Git/SVN/Editor.pm @@ -63,7 +63,7 @@ sub generate_diff { my @mods; while (defined($_ = get_record($diff_fh, "\0"))) { if ($state eq 'meta' && /^:(\d{6})\s(\d{6})\s - ($::sha1)\s($::sha1)\s + ($::oid)\s($::oid)\s ([MTCRAD])\d*$/xo) { push @mods, { mode_a => $1, mode_b => $2, sha1_a => $3, sha1_b => $4, |