(bug 44805) Set correct number separators for Northern Sami
[lhc/web/wiklou.git] / maintenance / importImages.php
index a8cd2ff..782f502 100644 (file)
@@ -64,7 +64,7 @@ $extensions = isset( $options['extensions'] )
        : $wgFileExtensions;
 
 # Search the path provided for candidates for import
-$files = findFiles( $dir, $extensions );
+$files = findFiles( $dir, $extensions, isset( $options['search-recursively'] ) );
 
 # Initialise the user for this operation
 $user = isset( $options['user'] )
@@ -326,12 +326,13 @@ USAGE: php importImages.php [options] <dir>
 <dir> : Path to the directory containing images to be imported
 
 Options:
---extensions=<exts>    Comma-separated list of allowable extensions, defaults to \$wgFileExtensions
+--extensions=<exts>     Comma-separated list of allowable extensions, defaults to \$wgFileExtensions
 --overwrite             Overwrite existing images with the same name (default is to skip them)
 --limit=<num>           Limit the number of images to process. Ignored or skipped images are not counted.
 --from=<name>           Ignore all files until the one with the given name. Useful for resuming
                         aborted imports. <name> should be the file's canonical database form.
 --skip-dupes            Skip images that were already uploaded under a different name (check SHA1)
+--search-recursively    Search recursively for files in subdirectories
 --sleep=<sec>           Sleep between files. Useful mostly for debugging.
 --user=<username>       Set username of uploader, default 'Maintenance script'
 --check-userblock       Check if the user got blocked during import.