Skip to content

Manage your WordPress site dependencies using the power of Composer, WP CLI, and wpackagist.org

Notifications You must be signed in to change notification settings

endriu84/wp-composer

 
 

Repository files navigation

WP Composer

WP Composer is a WP-CLI package for managing your WordPress theme and plugin dependencies. By using the power of WP-CLI and composer, you can declare the themes and plugins your WordPress site depends on.

Install

Installing as a WP-CLI package (preferred installation method)


wp package install rxnlabs/wp-composer-dependencies

Installing as a plugin

Clone this repo into plugins/ folder of your WordPress site, run:


composer install --no-dev --prefer-dist

This installs the plugin dependencies. Then, activate the plugin.

Requirements

  • PHP 5.4 and up
  • Requires WP-CLI version 0.24.0 and up.

Optional Requirements

Note: Only needed if you're using as a plugin and not as a WP-CLI package. Composer is useful in a lot of other scenarios. Learn more about Composer.

After installing as a WP-CLI package or as a plugin, run wp composer --help to see the list of commands and subcommands available.

WP Composer Help Output

Commands

Command Description
composer plugins Manage dependencies of installed plugins
composer themes Manage dependencies of installed themes
composer plugin Manage dependencies of a specific plugin
composer theme Manage dependencies of a specific theme
composer add Add installed plugins and themes to composer.json
composer install Install the dependencies of third-party themes and plugins

Hooks

List of hooks available for the plugin

Documentation and Examples

Learn more about the plugin and the commands available by visiting https://rxnlabs.github.io/wp-composer/

Note This plugin currently does not support premium plugins and themes, as well as plugins and themes not hosted on WordPress.org. This is a limitation I would like to fix at some point. In the meantime, you can manage your premium plugins in other ways such as submodules, subtrees, and plenty of other ways.

Bugs and Issues

When you find issues, please report theme:

Be sure to include any relevant details including PHP version, plugins installed on the site, error messages, themes install on the site, WP-CLI version.

About

Manage your WordPress site dependencies using the power of Composer, WP CLI, and wpackagist.org

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 98.5%
  • JavaScript 1.5%