I am trying to override the class FilePermissions (magento/framework/Setup/FilePermissions.php) but my changes are not taken in account while I use the bin/magento setup:upgrade

I tried :

  • To add a new preference in my di.xml, but the rewrite is not taken in account
  • To use a plugin instead of a rewrite but it didn't work either

It seem that the module Magento_Setup have some particular behavior compared to other modules in term of bootstrapping.

Does anyone succeed to override method during magento setup command ?

Thank for your help

  • Give us a good reason would you do that with setup upgrade? – André Ferraz Dec 5 '17 at 17:07
  • @AndréFerraz, I would like to change the way to check file permission for some sub directory of var. I got some big directory that Magento don't need to check. – Pierre Gauthier Dec 6 '17 at 8:39
  • @PierreGauthier did you find any solution for this? – Doni Wibowo Mar 13 '19 at 7:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.