I wanna move a module under app/code/vendor1
directory to app/code/vendor2
. I know that I should replace all namespace from vendor1/module1
to vendor2/module2
and replace all vendor1_module1
to vendre2_module2
(for example in registration.php file) and replace other things. so what is the best way to move a module in one directory into another module directory with the same functionality?
-
why do you want to move the modules/code ?– Krishna ijjadaOct 5, 2016 at 9:15
-
I get a sample module from github I wanna mode it to my vendor directory and then I will customise it– ali ghOct 5, 2016 at 10:38
-
I wanna move it to my vendor directory and then I will customise it– ali ghOct 5, 2016 at 11:21
1 Answer
There is no tool for migrating module functionality. One more option is if you want to override the functionality, you can override/extend the class instaed of migration.
You need to change the naming convention of the module you want to move by your module.
Check if the module has any dependency and migrate accordingly. if module dependents on other/core modules make sure you have to follow the dependency.