MediaWiki introduced a new entry point for the maintenance scripts.
I wrote https://www.mediawiki.org/wiki/Manual:Run.php to document it.
We don't especially need to do anything, as mw run <wiki> <script> [options] would work fine, but the mw goal is to call the relevant maintenance script, so we can add the run directly.
If we call a maintenance script without using run.php:
$ mw ... ******************************************************************************* NOTE: Do not run maintenance scripts directly, use maintenance/run.php instead! Running scripts directly has been deprecated in MediaWiki 1.40. It may not work for some (or any) scripts in the future. *******************************************************************************