Skip to content

Commit 8f2d23a

Browse files
committed
Update readme to include script info
1 parent c96e957 commit 8f2d23a

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

README.md

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,19 @@ composer global require balbuf/composer-wp
1919
composer install
2020
```
2121

22+
Alternatively, you can include this step as a script that composer will execute before installing or updating
23+
packages:
24+
25+
```json
26+
"scripts": {
27+
"pre-cmd": [
28+
"composer global require balbuf/composer-wp"
29+
],
30+
"pre-install-cmd": "@pre-cmd",
31+
"pre-update-cmd": "@pre-cmd"
32+
}
33+
```
34+
2235
## About
2336

2437
Similar to [wpackagist](http://wpackagist.org/), Composer-WP leverages the official WordPress SVN repositories
@@ -429,15 +442,17 @@ The built-in installer has the following properties:
429442
meaning if you wish to use the sample WordPress themes (e.g. "twentysixteen") or plugins,
430443
you'll have to require them separately in `composer.json`. In order to use this option,
431444
the `wordpress-path` _and_ `wp-content-path` properties must be defined (default values
432-
are considered).
445+
are considered) and said paths must exist (e.g. there are packages that are installed to these
446+
paths).
433447

434448
* **mu-plugin-autoloader** (_default:_ `true`)
435449

436450
This option allows you to enable or disable the included mu-plugins autoloader. If enabled,
437451
all regular plugins installed in the mu-plugins directory will be automatically loaded in
438452
WordPress in the order that they are defined in `composer.json`. Additionally, the composer
439453
autoloader will be loaded into WordPress. In order to use this option, either the
440-
`wp-content-path` or `wpmu-plugin-dir` must be defined (default values are considered).
454+
`wp-content-path` or `wpmu-plugin-dir` must be defined (default values are considered)
455+
and must exist.
441456

442457
* **autoloader-path**
443458

0 commit comments

Comments
 (0)