By jibran on
Change record status:
Draft (View all draft change records)
Project:
Introduced in branch:
8.0.x
Introduced in version:
8.0.0-beta7
Issue links:
Description:
In Drupal we have more or less 6 non-standard extensions to represent PHP files. Now all these files end with .php extension.
| Old | → | New |
|---|---|---|
| foo.module | → | foo.module.php |
| foo.install | → | foo.install.php |
| foo.inc | → | foo.inc.php |
| bar.theme | → | bar.theme.php |
| baz.profile | → | baz.profile.php |
| qux.engine | → | qux.engine.php |
This command line script will help in renaming files within contrib or custom modules and themes.
for f in $(find . -name "*.module" -o -name "*.profile" -o -name "*.theme" -o -name "*.install" -o -name "*.inc" -o -name "*.engine"); do mv $f ${f}.php; done
Renaming through git (use git mv instead of mv):
for f in $(find . -name "*.module" -o -name "*.profile" -o -name "*.theme" -o -name "*.install" -o -name "*.inc" -o -name "*.engine"); do git mv $f ${f}.php; done
Impacts:
Site builders, administrators, editors
Module developers
Themers