cookbook 'wp-cli', '= 0.1.3'
wp-cli (4) Versions 0.1.3 Follow4
Installs wp-cli
cookbook 'wp-cli', '= 0.1.3', :supermarket
knife supermarket install wp-cli
knife supermarket download wp-cli
wp-cli Chef Cookbook
Installs WP-CLI.
Attributes
<table>
<tr>
<th>Key</th>
<th>Type</th>
<th>Description</th>
<th>Default</th>
</tr>
<tr>
<td><tt>['wp-cli']['dir']</tt></td>
<td>String</td>
<td>The installation dir</td>
<td><tt>/usr/local/share/wp-cli</tt></td>
</tr>
<tr>
<td><tt>['wp-cli']['link']</tt></td>
<td>String</td>
<td>The binary link</td>
<td><tt>/usr/local/bin/wp</tt></td>
</tr>
</table>
Usage
Just include wp-cli
in your node's run_list
:
{ "name":"my_node", "run_list": [ "recipe[wp-cli]" ] }
Resources / Providers
This cookbook includes an LWRP for execute wp-cli
commands
wp_cli_command
Execute WP-CLI with the desired command and arguments.
Parameters:
-
command
- WP-CLI command. -
args
- Hash with the command arguments -
stdin
- Free text to the standard input (seewp core config --extra-php
) -
cwd
- WordPress installation path. -
user
- Execute WP-CLI with under the desired user privileges.
Examples:
Execute wp core is-installed
over the WordPress installation directory.
wp_cli_command 'core is-installed' do
args(
'path' => '/path/to/wordpress/',
'allow-root' => ''
)
end
or
wp_cli_command 'core is-installed' do
args(
'allow-root' => ''
)
cwd '/path/to/wordpress/'
end
Contributing
- Fork the repository on Github
- Create a named feature branch (like
add_component_x
) - Write your change
- Test your change
- Submit a Pull Request using Github
Author(s)
Rubem Nakamura
License
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
wp-cli CHANGELOG
0.1.3
- [Maks3w] Recipe for bash completition.
- [Maks3w] Create a chef definition for abstract the use of wp-cli
0.1.2
- [Maks3w] Use /usr/local for binaries and share
- [cimocimocimo] Fixes error with setting node attribute
0.1.1
- [Rubem Nakamura] - Added license and Added metadata.json
0.1.0
- [Rubem Nakamura] - Initial release of wp-cli