M
M
Maxim Grechushnikov2015-12-29 18:43:20
Yii
Maxim Grechushnikov, 2015-12-29 18:43:20

Composer, Yii2: How to start script execution during installation?

Composer puts the module to Yii2
Upon completion of the installer, the information is automatically written to the database table, they say I'm installed, ready for activation on the site.
Two questions, how to tell the composer - execute the command, how to work with the database from the composer?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Rikcon, 2015-12-29
@maxyc_webber

https://getcomposer.org/doc/articles/scripts.md
post-install-cmd
And write what you want there, you can write a python script and execute it, or in php.
How to work with the database, the question itself disappears from the above.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question