[PATCH 2/4] remote-mediawiki: allow fetching namespaces with spaces
- From
Antoine Beaupré <anarcat@debian.org>
- Date
- Oct 29, 2017, 16:08 UTC
- Message-ID
- <20171029160857.29460-3-anarcat@debian.org>
- In-Reply-To
- <20171029160857.29460-1-anarcat@debian.org>
From: Ingo Ruhnke <grumbel@gmail.com>
we still want to use spaces as separators in the config, but we should allow the user to specify namespaces with spaces, so we use underscore for this.
Reviewed-by: Antoine Beaupré <anarcat@debian.org> Signed-off-by: Antoine Beaupré <anarcat@debian.org> --- contrib/mw-to-git/git-remote-mediawiki.perl | 1 + 1 file changed, 1 insertion(+)
diff --git a/contrib/mw-to-git/git-remote-mediawiki.perl b/contrib/mw-to-git/git-remote-mediawiki.perl index 1c5e39831..fc48846a1 100755 --- a/contrib/mw-to-git/git-remote-mediawiki.perl +++ b/contrib/mw-to-git/git-remote-mediawiki.perl @@ -66,6 +66,7 @@ chomp(@tracked_categories); # Just like @tracked_categories, but for MediaWiki namespaces. my @tracked_namespaces = split(/[ \n]/, run_git("config --get-all remote.${remotename}.namespaces")); +for (@tracked_namespaces) { s/_/ /g; } chomp(@tracked_namespaces); # Import media files on pull
-- 2.11.0