Wp-cli: Have a specific `type` for WP-CLI packages

Created on 17 Mar 2016  路  4Comments  路  Source: wp-cli/wp-cli

I recommend having the WP-CLI packages be regrouped under a common Composer type, like wp-cli-package.

In this way, you can provide a Composer plugin to define a custom installer for this type, which allows you to exert more control over the installation process (see Setting up and using custom installers ).

package package-install

Most helpful comment

馃殺 馃殺

All 4 comments

I recommend having the WP-CLI packages be regrouped under a common Composer type

Does this have to be something package authors remember to do, or is it something we can enforce?

This is done by the package authors, by adding the type key to their composer.json.

As an example, this is used for WordPress plugins, by setting "type" => "wordpress-plugin" in the plugin's composer.json. Together with https://github.com/composer/installers, this makes sure that plugins get installed into the wp-content/plugins folder instead of the vendor folder.

Cool. I think we need to do three things:

  • [x] Update the docs.
  • [x] Ensure wp scaffold package includes the type.
  • [x] Submit a bunch of PRs against packages in the package index.

馃殺 馃殺

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sir-gon picture sir-gon  路  4Comments

NateWr picture NateWr  路  3Comments

AndrewCloss picture AndrewCloss  路  3Comments

vercotux picture vercotux  路  3Comments

jacklenox picture jacklenox  路  3Comments