cedaro / satispress

Expose installed WordPress plugins and themes as Composer packages.
500 stars 48 forks source link

Need second vendor prefix for themes #118

Closed rfair404 closed 4 years ago

rfair404 commented 4 years ago

I'm using Satispress to host both plugins and themes. In the composer extra -> installer-paths you can specify where to install packages by type (e.g. wordpress-plugin). Satispress defaults to using the same vendor prefix for both plugins and themes. It would be helpful to have a custom prefix for themes so that they can be configured to install in the correct directory.

bradyvercher commented 4 years ago

The install path isn't based on the vendor prefix, but rather the package type. SatisPress uses the wordpress-plugin and wordpress-theme types based on the type of package, so you should already be able to configure themes to be installed in the correct directory.

Here's a snippet I use in one of my projects to install packages in a custom directory:

"extra": {
    "installer-paths": {
      "content/mu-plugins/{$name}": [ "type:wordpress-muplugin" ],
      "content/plugins/{$name}": [ "type:wordpress-plugin" ],
      "content/themes/{$name}": [ "type:wordpress-theme" ]
    }
}

Let me know if you had something else in mind or if I'm missing something though.