php-dev-tools icon indicating copy to clipboard operation
php-dev-tools copied to clipboard

Make index.php files and header management easier

Open Quetzacoalt91 opened this issue 6 years ago • 2 comments

We request all PrestaShop modules provide a index.php files in each folder. This tool (https://github.com/jmcollin/autoindex) can do it automatically, but we should provide it via packagist to make its installation & use automatic.

Also, we should have a tool (which currently does not exist) which could maintain the headers of a whole project easily.

Quetzacoalt91 avatar Jul 25 '19 15:07 Quetzacoalt91

If I'm not wrong, php-dev-tools now fits 100% of the needs for header management (and we are deploying it on every native modules).

Then comes the question of autoindex.

So I guess, to fit 100% of the needs of "have a index.php in all folders to secure" we need

  • a CLI tool able to put the right index.php file (with license headers) in every folders and subfolders of targeted folder (+ ability to exclude some folders)
  • the CLI tool must be embedded into php-dev-tools
  • it needs to be documented
  • the CLI tool needs a dry-run option so we can run it in a GitHub Action
  • we need to deploy it on every native modules to make it a standard

Did I forget something ?

matks avatar Jun 27 '20 12:06 matks

:+1: @matks

Progi1984 avatar Sep 10 '20 14:09 Progi1984