summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorCélestin Matte <celestin.matte@ensimag.fr>2013-06-14 13:50:26 (GMT)
committerJunio C Hamano <gitster@pobox.com>2013-06-14 16:02:17 (GMT)
commit4f1b7883bc9b614f3a91eff7aa46cfdc85156ceb (patch)
tree62822e15dfbfd241db6b8d7b9635929146715adb /contrib
parentb835baf65c10c2511a0bb9600b09ac3c7a53e818 (diff)
downloadgit-4f1b7883bc9b614f3a91eff7aa46cfdc85156ceb.zip
git-4f1b7883bc9b614f3a91eff7aa46cfdc85156ceb.tar.gz
git-4f1b7883bc9b614f3a91eff7aa46cfdc85156ceb.tar.bz2
git-remote-mediawiki: assign a variable as undef and make proper indentation
Explicitly assign local variable $/ as undef and make a proper one-instruction-by-line indentation Signed-off-by: Célestin Matte <celestin.matte@ensimag.fr> Signed-off-by: Matthieu Moy <matthieu.moy@grenoble-inp.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/mw-to-git/git-remote-mediawiki.perl5
1 files changed, 4 insertions, 1 deletions
diff --git a/contrib/mw-to-git/git-remote-mediawiki.perl b/contrib/mw-to-git/git-remote-mediawiki.perl
index 29fb614..d1cddab 100755
--- a/contrib/mw-to-git/git-remote-mediawiki.perl
+++ b/contrib/mw-to-git/git-remote-mediawiki.perl
@@ -338,7 +338,10 @@ sub run_git {
my $args = shift;
my $encoding = (shift || "encoding(UTF-8)");
open(my $git, "-|:$encoding", "git " . $args);
- my $res = do { local $/; <$git> };
+ my $res = do {
+ local $/ = undef;
+ <$git>
+ };
close($git);
return $res;