Manual:populateImageSha1.php

From Linux Web Expert

The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
<td class="mw-version-versionbox" title="<translate nowrap> The latest stable version is <tvar name=1>1.41</tvar></translate>">
<translate> ≥</translate> 1.19
<translate> MediaWiki version:</translate>

Détails

Le fichier populateImageSha1.php est un script de maintenance servant à initialiser le champ img_sha1. The img_sha1 field in the image table is used to store SHA-1 hash of the file contents in base 36 format.

This script runs by default when you run update.php .

Options et arguments

Option Description Nécessaire ?
--multiversiononly Calculate only for files with several versions <translate> Optional</translate>
--method Use 'pipe' to pipe to mysql command line, default uses Database class <translate> Optional</translate>
--file Fix for a specific file, without File: namespace prefixed <translate> Optional</translate>
--force Recalculate sha1 for rows that already have a value <translate> Optional</translate>

Utilisation

php maintenance/populateImageSha1.php [ --multiversiononly| --method| --file| --force ]
Terminal


<translate> Whenever the script runs, it makes a note in the database and will not run again.</translate> <translate> If you want to run the script again, run the command with the <tvar name=1>--force</tvar> option.</translate>

Voir aussi