A
A
alex stephen2015-08-05 12:03:15
PHP
alex stephen, 2015-08-05 12:03:15

Composer: require-dev to specific folder?

There is a composer package that I want to install in a specific folder. Did something like this

"require-dev": {
    "potsky/pimp-my-log": "*"
}, 
#.......*тут autoload*......
  "extra": {
    "installer-paths": {
      "pimpmylog/": ["potsky/pimp-my-log"]
    }
  }

Only it is still put in vendor.
ps It would be absolutely ideal if a certain folder from potsky / pimp-my-log is thrown into pimpmylog, if this is even possible

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
D', 2015-08-05
@berezuev

Note: You cannot use this to change the path of any package. This is only applicable to packages that require composer/installers and use a custom type that it handles.

From here https://getcomposer.org/doc/faqs/how-do-i-install-...
For those in the tank:
"installer-paths" can only be used for packages that use composer/installers .
You cannot install a specific package in a custom directory.
You can only change the name of the vendor directory to something else with:
"config": {
        "vendor-dir": "plugins"
}

But still, all packages will be installed in this directory.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question