Jump to content
MediaWiki

Manual:pruneFileCache.php

From mediawiki.org
MediaWiki version:
≥ 1.19
MediaWiki file: pruneFileCache.php
Location: maintenance/
Source code: master1.43.11.42.61.39.12
Classes: PruneFileCache

Details

[edit ]

pruneFileCache.php file is a maintenance script to prune file cache for pages, objects, resources, etc.

This script requires $wgUseFileCache = true; to be set in LocalSettings.php in order to prune the file cache from $wgFileCacheDirectory .

Options/Arguments

[edit ]
Option Description Required?
--agedays How many days old files must be in order to delete Required
--subdir Prune one $wgFileCacheDirectory subdirectory name Optional

Usage

[edit ]
phpmaintenance/run.phppruneFileCache--agedaysdays[--subdir]
Terminal
$ php maintenance/run.php pruneFileCache --agedays 7
Pruning `/var/www/html/wiki/images/cache` directory...
Done pruning `/var/www/html/wiki/images/cache` directory
In MediaWiki version 1.39.12 and earlier, you must invoke maintenance scripts using php maintenance/scriptName.php instead of php maintenance/run.php scriptName.

See also

[edit ]

AltStyle によって変換されたページ (->オリジナル) /