2012-11-13 20:12:13 +01:00
WP-CLI
========
wp-cli is a set of command-line tools for managing WordPress installations.
2011-09-10 15:04:57 +02:00
2012-11-13 20:12:13 +01:00
Where can I get more info?
--------------------------
For documentation, usage, and examples, check out [wp-cli.org ](http://wp-cli.org/ ).
2012-10-09 00:36:24 +03:00
2012-11-13 20:12:13 +01:00
I'm running into troubles, what can I do?
-----------------------------------------
2011-09-10 15:04:57 +02:00
2012-11-13 20:12:13 +01:00
To suggest a feature, report a bug, or general discussion, visit the [issues section ](https://github.com/wp-cli/wp-cli/issues ).
Who's behind this thing?
------------------------
We are [Andreas Creten ](https://github.com/andreascreten ) and [Cristi Burcă ](https://github.com/scribu ), friendly guys from Europe.
2012-11-13 21:14:08 +02:00
A complete list of contributors can be found [here ](https://github.com/wp-cli/wp-cli/contributors ).
2012-11-13 20:12:13 +01:00
Need even more info?
--------------------
2012-11-14 10:33:35 +02:00
Read our [wiki ](https://github.com/wp-cli/wp-cli/wiki ) and find out how to create your own commands with our [commands cookbook ](https://github.com/wp-cli/wp-cli/wiki/Commands-Cookbook ).
If you want to receive an email for every single commit, you can subscribe to the [wp-cli-commits ](https://groups.google.com/forum/?fromgroups=#!forum/wp-cli-commits ) mailing list.
2012-12-13 11:37:30 +00:00
Running tests
-------------
The tests use PHPUnit, which can be installed using [composer ](http://getcomposer.org/ ).
2012-12-13 11:38:19 +00:00
Once you've got composer installed, run:
2012-12-13 11:37:30 +00:00
composer.phar install --dev
2012-12-13 11:39:05 +00:00
Before running the tests, you'll need a MySQL user called `wp_cli_test` with the
password `password1` that has full privileges on the MySQL database `wp_cli_test` .
Running the following as root in MySQL should do the trick:
2012-12-13 11:37:30 +00:00
GRANT ALL PRIVILEGES ON wp_cli_test.* TO "wp_cli_test"@"localhost"
IDENTIFIED BY "password1";
2012-12-29 17:38:09 +02:00
2012-12-13 11:37:30 +00:00
Finally, to run the tests:
2012-12-29 17:41:13 +02:00
vendor/bin/phpunit
2012-12-13 11:37:30 +00:00
2012-12-13 11:46:34 +00:00
Most tests install WordPress from scratch. Since this is pretty slow, you can
2012-12-13 11:45:13 +00:00
use arguments to `phpunit` to only run the test that you're interested in:
2012-12-13 11:37:30 +00:00
2012-12-29 17:41:13 +02:00
vendor/bin/phpunit --filter test_function_you_want_to_run