B
B
Bal2013-05-28 19:56:33
PHP
Bal, 2013-05-28 19:56:33

A package manager for PHP that works directly from the application. Is there such a thing?

Continuing the theme of leaving the bicycle industry.

Interested in using some standard package manager called directly from a running PHP application.

To, say, unpack your application (or right away curl http://site.tld | gunzip ...), optionally launch the built-in web server, go to the browser - and poke into the modules for installation in the admin panel. Which, in turn, are not installed by a bicycle, but from a normal package manager.

It immediately comes to mind exec("php composer.phar"), but it's clumsy and not beautiful. Now, if composer had an API...

Has anyone come across a more elegant solution? Does anyone have any ideas on this subject? And then, after all, you have to do it through exec / composer.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
Nikita Gusakov, 2013-05-28
@hell0w0rd

If only composer had an API...

So he is! How do you think scripts are executed before / after / during, etc., installation?
getcomposer.org/doc/articles/scripts.md The
composer gives you full access to itself and the console.
github.com/hell0w0rd/skeleton-project/blob/v1.0/Installer.php - yesterday I made a script to create an application skeleton, not ideal, but it can serve as a starting point)
PS If you are not talking about installing from the console - there too nothing complicated, it's just not described in the docs.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question