summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2011-10-26 16:16:31 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2011-10-26 16:16:31 -0700
commit2ef89f38568c9bfa663a8c79354e6d2135fb6bf3 (patch)
treed227093caad0cb8e54171cda1c572b8afb68b7e0 /contrib
parentMerge branch 'jn/libperl-git-config' (diff)
parentgit-remote-mediawiki: don't include HTTP login/password in author (diff)
downloadtgif-2ef89f38568c9bfa663a8c79354e6d2135fb6bf3.tar.xz
Merge branch 'mm/mediawiki-author-fix'
* mm/mediawiki-author-fix: git-remote-mediawiki: don't include HTTP login/password in author
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/mw-to-git/git-remote-mediawiki4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/mw-to-git/git-remote-mediawiki b/contrib/mw-to-git/git-remote-mediawiki
index 0b32d18eaa..c18bfa1f15 100755
--- a/contrib/mw-to-git/git-remote-mediawiki
+++ b/contrib/mw-to-git/git-remote-mediawiki
@@ -109,6 +109,10 @@ $dumb_push = ($dumb_push eq "true");
my $wiki_name = $url;
$wiki_name =~ s/[^\/]*:\/\///;
+# If URL is like http://user:password@example.com/, we clearly don't
+# want the password in $wiki_name. While we're there, also remove user
+# and '@' sign, to avoid author like MWUser@HTTPUser@host.com
+$wiki_name =~ s/^.*@//;
# Commands parser
my $entry;