]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'mm/mediawiki-file-attachments'
authorJunio C Hamano <gitster@pobox.com>
Fri, 13 Jul 2012 22:36:53 +0000 (15:36 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 13 Jul 2012 22:36:53 +0000 (15:36 -0700)
"mediawiki" remote helper (in contrib/) learned to handle file
attachments.

* mm/mediawiki-file-attachments:
  git-remote-mediawiki: improve support for non-English Wikis
  git-remote-mediawiki: import "File:" attachments
  git-remote-mediawiki: split get_mw_pages into smaller functions
  git-remote-mediawiki: send "File:" attachments to a remote wiki
  git-remote-mediawiki: don't "use encoding 'utf8';"
  git-remote-mediawiki: don't compute the diff when getting commit message

1  2 
contrib/mw-to-git/git-remote-mediawiki

index c07b4f0ee6099fd8329615ac0d5860b7db6db6ec,063a978a6ec450a96a08d57b8693e76cf1f17587..6b128e88e8aeb6502d82d47be61254382dc75208
@@@ -70,8 -69,15 +66,13 @@@ chomp(@tracked_pages)
  my @tracked_categories = split(/[ \n]/, run_git("config --get-all remote.". $remotename .".categories"));
  chomp(@tracked_categories);
  
+ # Import media files too.
+ my $import_media = run_git("config --get --bool remote.". $remotename .".mediaimport");
+ chomp($import_media);
+ $import_media = ($import_media eq "true");
  my $wiki_login = run_git("config --get remote.". $remotename .".mwLogin");
 -# TODO: ideally, this should be able to read from keyboard, but we're
 -# inside a remote helper, so our stdin is connect to git, not to a
 -# terminal.
 +# Note: mwPassword is discourraged. Use the credential system instead.
  my $wiki_passwd = run_git("config --get remote.". $remotename .".mwPassword");
  my $wiki_domain = run_git("config --get remote.". $remotename .".mwDomain");
  chomp($wiki_login);