|
1 | | -WP-CLI Valet Command |
2 | | -==================== |
| 1 | +# WP-CLI Valet Command |
3 | 2 |
|
4 | | -Quick links: [Installing](#installing) | [Contributing](#contributing) |
| 3 | +White-glove services for turn-key installs in seconds. |
5 | 4 |
|
6 | | -## Overview |
7 | | -``` |
8 | | -NAME |
| 5 | +[](https://travis-ci.org/aaemnnosttv/wp-cli-valet-command) |
9 | 6 |
|
10 | | - wp valet |
| 7 | +Quick links: [Using](#using) | [Installing](#installing) | [Contributing](#contributing) |
11 | 8 |
|
12 | | -DESCRIPTION |
| 9 | +## Using |
13 | 10 |
|
14 | | - Zonda is golden. |
| 11 | +This package implements the following commands: |
15 | 12 |
|
16 | | -SYNOPSIS |
| 13 | +### wp valet new |
17 | 14 |
|
18 | | - wp valet <command> |
| 15 | +Create a new WordPress install -- fast |
19 | 16 |
|
20 | | -SUBCOMMANDS |
| 17 | +~~~ |
| 18 | +wp valet new <name> [--project=<project>] [--version=<version>] [--locale=<locale>] [--db=<db>] [--dbname=<dbname>] [--dbuser=<dbuser>] [--dbpass=<dbpass>] [--dbprefix=<dbprefix>] [--admin_user=<username>] [--admin_password=<password>] [--admin_email=<email>] [--unsecure] [--portable] |
| 19 | +~~~ |
21 | 20 |
|
22 | | - new Create a new WordPress install -- fast |
| 21 | +This command will spin up a new WordPress installation -- complete with database and https |
| 22 | +_ready-to-use in your browser_ faster than you can put your pants on. |
23 | 23 |
|
24 | | -``` |
| 24 | +**OPTIONS** |
25 | 25 |
|
26 | | -## `new` |
| 26 | + <name> |
| 27 | + Site domain name without TLD. This will become the directory name of the project root. |
| 28 | + Eg: To create an install for example.dev, `wp valet new example` |
27 | 29 |
|
28 | | -Currently the only valet subcommand, this command can spin up a new WordPress installation, complete with DB, and ready to use in your browser over https faster than you can put your pants on. |
| 30 | + [--project=<project>] |
| 31 | + The WordPress project to install. Choose from any project supported by Laravel Valet. |
| 32 | + --- |
| 33 | + default: wp |
| 34 | + options: |
| 35 | + - wp |
| 36 | + - bedrock |
| 37 | + --- |
29 | 38 |
|
30 | | -You should have some understanding of how Valet works, especially the portion on [Serving Sites](https://laravel.com/docs/5.2/valet#serving-sites) |
| 39 | + [--version=<version>] |
| 40 | + WordPress version to install. |
| 41 | + --- |
| 42 | + default: latest |
| 43 | + --- |
31 | 44 |
|
32 | | -From the terminal, within a Valet "parked" directory, you can now run `wp valet new my-project` |
33 | | -Once complete, you can now view your new site at https://my-project.dev. |
| 45 | + [--locale=<locale>] |
| 46 | + Select which language you want to install. |
| 47 | + |
| 48 | + [--db=<db>] |
| 49 | + Database driver to provision the site with. |
| 50 | + --- |
| 51 | + default: mysql |
| 52 | + options: |
| 53 | + - mysql |
| 54 | + - sqlite |
| 55 | + --- |
| 56 | + |
| 57 | + [--dbname=<dbname>] |
| 58 | + Database name (MySQL only). |
| 59 | + Defaults to 'wp_<name>'. |
| 60 | + |
| 61 | + [--dbuser=<dbuser>] |
| 62 | + Database User (MySQL only). |
| 63 | + --- |
| 64 | + default: root |
| 65 | + --- |
| 66 | + |
| 67 | + [--dbpass=<dbpass>] |
| 68 | + Set the database user password (MySQL only). |
| 69 | + --- |
| 70 | + Default: '' |
| 71 | + --- |
| 72 | + |
| 73 | + [--dbprefix=<dbprefix>] |
| 74 | + Set the database table prefix. |
| 75 | + --- |
| 76 | + default: 'wp_' |
| 77 | + --- |
| 78 | + |
| 79 | + [--admin_user=<username>] |
| 80 | + The username to create for the WordPress admin user. |
| 81 | + --- |
| 82 | + default: admin |
| 83 | + --- |
| 84 | + |
| 85 | + [--admin_password=<password>] |
| 86 | + The password to create for the WordPress admin user. |
| 87 | + --- |
| 88 | + default: admin |
| 89 | + --- |
| 90 | + |
| 91 | + [--admin_email=<email>] |
| 92 | + The email to use for the WordPress admin user. |
| 93 | + |
| 94 | + [--unsecure] |
| 95 | + Provision the site for http rather than https. |
| 96 | + |
| 97 | + [--portable] |
| 98 | + Provision the site to be portable. Implies --unsecure and --db=sqlite. |
| 99 | + |
| 100 | + |
| 101 | + |
| 102 | +### wp valet destroy |
| 103 | + |
| 104 | +Completely remove an installation. |
| 105 | + |
| 106 | +~~~ |
| 107 | +wp valet destroy <name> [--yes] |
| 108 | +~~~ |
| 109 | + |
| 110 | +This will drop the database, and delete all of the files as well as |
| 111 | +remove any self-signed TLS certificate that was generated for serving |
| 112 | +this install over https. |
| 113 | + |
| 114 | +**OPTIONS** |
| 115 | + |
| 116 | + <name> |
| 117 | + Site domain name without TLD. It should match the directory name of the project root. |
| 118 | + |
| 119 | + [--yes] |
| 120 | + Pre-approve the confirmation to delete all files and drop the database. |
34 | 121 |
|
35 | 122 | ## Installing |
36 | 123 |
|
37 | 124 | ### Prerequisites |
38 | | -This command leverages [Laravel Valet](https://laravel.com/docs/5.2/valet#installation) which is installed globally via Composer. |
| 125 | + |
| 126 | +This command leverages [Laravel Valet](https://laravel.com/docs/5.2/valet#installation) -- the development environment for Mac minimalists. |
| 127 | +Because of this **support is unfortunately limited to Mac only**. |
| 128 | + |
39 | 129 | Follow the [installation instructions](https://laravel.com/docs/5.2/valet#installation) on the Laravel documentation to get started. |
| 130 | +This is what makes it possible to load a site in your browser immediately after creating it, without any other configuration. |
| 131 | + |
| 132 | +You will also need some understanding of how Valet works, especially the portion on [Serving Sites](https://laravel.com/docs/5.2/valet#serving-sites). |
40 | 133 |
|
41 | 134 | Installing this package requires WP-CLI v0.23.0 or greater. Update to the latest stable release with `wp cli update`. |
42 | | -Once you've done so, you can install this package with `wp package install aaemnnosttv/wp-cli-valet-command` |
43 | 135 |
|
44 | | -## Database Options |
45 | | -New sites create a new MySQL database by default, but the `new` command also supports using [SQLite](https://www.sqlite.org/) for a completely portable install. Simply add `--db=sqlite` when running `wp valet new`. |
| 136 | +Once you've done so, you can install this package with `wp package install aaemnnosttv/wp-cli-valet-command`. |
46 | 137 |
|
47 | 138 | ## Contributing |
48 | 139 |
|
49 | | -Code and ideas are more than welcome. |
| 140 | +We appreciate you taking the initiative to contribute to this project. |
| 141 | + |
| 142 | +Contributing isn’t limited to just code. We encourage you to contribute in the way that best fits your abilities, by writing tutorials, giving a demo at your local meetup, helping other users with their support questions, or revising our documentation. |
| 143 | + |
| 144 | +### Reporting a bug |
| 145 | + |
| 146 | +Think you’ve found a bug? We’d love for you to help us get it fixed. |
| 147 | + |
| 148 | +Before you create a new issue, you should [search existing issues](https://github.com/aaemnnosttv/wp-cli-valet-command/issues?q=label%3Abug%20) to see if there’s an existing resolution to it, or if it’s already been fixed in a newer version. |
| 149 | + |
| 150 | +Once you’ve done a bit of searching and discovered there isn’t an open or fixed issue for your bug, please [create a new issue](https://github.com/aaemnnosttv/wp-cli-valet-command/issues/new) with the following: |
| 151 | + |
| 152 | +1. What you were doing (e.g. "When I run `wp post list`"). |
| 153 | +2. What you saw (e.g. "I see a fatal about a class being undefined."). |
| 154 | +3. What you expected to see (e.g. "I expected to see the list of posts.") |
| 155 | + |
| 156 | +Include as much detail as you can, and clear steps to reproduce if possible. |
| 157 | + |
| 158 | +### Creating a pull request |
| 159 | + |
| 160 | +Want to contribute a new feature? Please first [open a new issue](https://github.com/aaemnnosttv/wp-cli-valet-command/issues/new) to discuss whether the feature is a good fit for the project. |
| 161 | + |
| 162 | +Once you've decided to commit the time to seeing your pull request through, please follow our guidelines for creating a pull request to make sure it's a pleasant experience: |
| 163 | + |
| 164 | +1. Create a feature branch for each contribution. |
| 165 | +2. Submit your pull request early for feedback. |
| 166 | +3. Include functional tests with your changes. [Read the WP-CLI documentation](https://wp-cli.org/docs/pull-requests/#functional-tests) for an introduction. |
| 167 | +4. Follow the [WordPress Coding Standards](http://make.wordpress.org/core/handbook/coding-standards/). |
| 168 | + |
50 | 169 |
|
51 | | -Please [open an issue](https://github.com/aaemnnosttv/wp-cli-valet-command/issues) with questions, feedback, and violent dissent. |
| 170 | +*This README.md is generated dynamically from the project's codebase using `wp scaffold package-readme` ([doc](https://github.com/wp-cli/scaffold-package-command#wp-scaffold-package-readme)). To suggest changes, please submit a pull request against the corresponding part of the codebase.* |
0 commit comments