From vss2svn-commits at lists.pumacode.org Fri Feb 1 19:13:06 2008 From: vss2svn-commits at lists.pumacode.org (vss2svn-commits@lists.pumacode.org) Date: Fri Feb 1 19:13:09 2008 Subject: r335 - toby: /trunk/script/Vss2Svn/Dumpfile/AutoProps.pm Message-ID: <20080202001306.5472815CF5E@cp.thetahost.com> Author: toby Date: Fri Feb 1 19:13:05 2008 New Revision: 335 Log: Require version 0.08 of Text::Glob Modified: trunk/script/Vss2Svn/Dumpfile/AutoProps.pm Modified: trunk/script/Vss2Svn/Dumpfile/AutoProps.pm ============================================================================== --- trunk/script/Vss2Svn/Dumpfile/AutoProps.pm (original) +++ trunk/script/Vss2Svn/Dumpfile/AutoProps.pm Fri Feb 1 19:13:05 2008 @@ -3,7 +3,7 @@ use warnings; use strict; use Config::Ini; -use Text::Glob; +use Text::Glob 0.08; ############################################################################### # new @@ -17,21 +17,20 @@ $self->{entries} = (); my ($enabled) = $config->get (['miscellany', 'enable-auto-props']); - if (defined $enabled && $enabled eq "yes") - { + if (defined $enabled && $enabled eq "yes") { my $autoprops_list = $config->get (['auto-props']); - # see http://subversion.tigris.org/servlets/ReadMsg?list=svn&msgNo=29642 - # matches are performed in a case-insensitive manner + # see http://subversion.tigris.org/servlets/ReadMsg?list=svn&msgNo=29642 + # matches are performed in a case-insensitive manner - my ($glob, $autoprops); - while (($glob, $autoprops) = each %{ $autoprops_list }) { - my $entry = (); - my $regex = Text::Glob::glob_to_regex_string($glob); - $entry->{glob} = qr/$regex/i; - $entry->{props} = $autoprops; - push @{$self->{entries}}, $entry; - } + my ($glob, $autoprops); + while (($glob, $autoprops) = each %{ $autoprops_list }) { + my $entry = (); + my $regex = Text::Glob::glob_to_regex_string($glob); + $entry->{glob} = qr/$regex/i; + $entry->{props} = $autoprops; + push @{$self->{entries}}, $entry; + } } $self = bless($self, $class); From vss2svn-commits at lists.pumacode.org Fri Feb 1 19:36:13 2008 From: vss2svn-commits at lists.pumacode.org (vss2svn-commits@lists.pumacode.org) Date: Fri Feb 1 19:36:15 2008 Subject: r336 - toby: /trunk/script/Vss2Svn/Dumpfile.pm Message-ID: <20080202003613.426D015CF60@cp.thetahost.com> Author: toby Date: Fri Feb 1 19:36:12 2008 New Revision: 336 Log: Add patch from cd via mailing list to output Text-content-length header for zero-length files: http://thread.gmane.org/gmane.comp.version-control.subversion.vss2svn.user/2220/focus=2224 Modified: trunk/script/Vss2Svn/Dumpfile.pm Modified: trunk/script/Vss2Svn/Dumpfile.pm ============================================================================== --- trunk/script/Vss2Svn/Dumpfile.pm (original) +++ trunk/script/Vss2Svn/Dumpfile.pm Fri Feb 1 19:36:12 2008 @@ -859,13 +859,13 @@ } else { $textlen = length($text); } - return if ($textlen + $proplen == 0); + return if ($textlen + $proplen == 0 && !defined $file); if ($proplen > 0) { print $fh "Prop-content-length: $proplen\n"; } - if ($textlen > 0) { + if (defined $file || $textlen > 0) { print $fh "Text-content-length: $textlen\n"; print $fh "Text-content-md5: $digest\n" if $self->{do_md5}; }