This is a more cosmetic question ...
I am using composer.phar in an existing project to autoload my classes.
This is an example composer.json snippet for my project named Acme :
{ "autoload": { "psr-0": { "Acme\\Mail": "modules/mail/src/", } } }
and the parameter of my file structure is similar:
app.php composer.phar vendor/ modules/ mail/ src/ Acme/ Mail.php (contains Acme\Mail\Mail.php)
I have to stick to the "modules / mail" folder in my case and cannot rename them.
This basically works , but I need to create an additional Acme folder below src , which is a bit ugly.
How should startup be determined if I want to leave the highest part of the Acme namespace in my mail folder so that it looks like this:
app.php composer.phar vendor/ modules/ mail/ src/ Mail.php (contains Acme\Mail\Mail.php)
and i can still use it in php file:
use Acme\Mail; $mail = new Mail();
Or is it not possible?
source share