Skip to content

Commit 1b5a3d5

Browse files
Generate a README
1 parent bcbdd4c commit 1b5a3d5

File tree

2 files changed

+190
-3
lines changed

2 files changed

+190
-3
lines changed

README.md

Lines changed: 185 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,185 @@
1+
wp-cli/language-command
2+
=======================
3+
4+
Manage language packs.
5+
6+
[![Build Status](https://travis-ci.org/wp-cli/language-command.svg?branch=master)](https://travis-ci.org/wp-cli/language-command)
7+
8+
Quick links: [Using](#using) | [Installing](#installing) | [Contributing](#contributing)
9+
10+
## Using
11+
12+
This package implements the following commands:
13+
14+
### wp language core activate
15+
16+
Activate a given language.
17+
18+
~~~
19+
wp language core activate <language>
20+
~~~
21+
22+
<language>
23+
Language code to activate.
24+
25+
**EXAMPLES**
26+
27+
$ wp core language activate ja
28+
Success: Language activated.
29+
30+
31+
32+
### wp language core install
33+
34+
Install a given language.
35+
36+
~~~
37+
wp language core install <language> [--activate]
38+
~~~
39+
40+
Downloads the language pack from WordPress.org.
41+
42+
<language>
43+
Language code to install.
44+
45+
[--activate]
46+
If set, the language will be activated immediately after install.
47+
48+
**EXAMPLES**
49+
50+
# Install the Japanese language.
51+
$ wp core language install ja
52+
Success: Language installed.
53+
54+
55+
56+
### wp language core list
57+
58+
List all available languages.
59+
60+
~~~
61+
wp language core list [--field=<field>] [--<field>=<value>] [--fields=<fields>] [--format=<format>]
62+
~~~
63+
64+
[--field=<field>]
65+
Display the value of a single field
66+
67+
[--<field>=<value>]
68+
Filter results by key=value pairs.
69+
70+
[--fields=<fields>]
71+
Limit the output to specific fields.
72+
73+
[--format=<format>]
74+
Accepted values: table, csv, json. Default: table
75+
76+
**AVAILABLE FIELDS**
77+
78+
These fields will be displayed by default for each translation:
79+
80+
* language
81+
* english_name
82+
* native_name
83+
* status
84+
* update
85+
* updated
86+
87+
These fields are optionally available:
88+
89+
* version
90+
* package
91+
92+
**EXAMPLES**
93+
94+
# List language,english_name,status fields of available languages.
95+
$ wp core language list --fields=language,english_name,status
96+
+----------------+-------------------------+-------------+
97+
| language | english_name | status |
98+
+----------------+-------------------------+-------------+
99+
| ar | Arabic | uninstalled |
100+
| ary | Moroccan Arabic | uninstalled |
101+
| az | Azerbaijani | uninstalled |
102+
103+
104+
105+
### wp language core uninstall
106+
107+
Uninstall a given language.
108+
109+
~~~
110+
wp language core uninstall <language>
111+
~~~
112+
113+
<language>
114+
Language code to uninstall.
115+
116+
**EXAMPLES**
117+
118+
$ wp core language uninstall ja
119+
Success: Language uninstalled.
120+
121+
122+
123+
### wp language core update
124+
125+
Update installed languages.
126+
127+
~~~
128+
wp language core update [--dry-run]
129+
~~~
130+
131+
Updates installed languages for core, plugins and themes.
132+
133+
[--dry-run]
134+
Preview which translations would be updated.
135+
136+
**EXAMPLES**
137+
138+
$ wp core language update
139+
Updating 'Japanese' translation for Akismet 3.1.11...
140+
Downloading translation from https://downloads.wordpress.org/translation/plugin/akismet/3.1.11/ja.zip...
141+
Translation updated successfully.
142+
Updating 'Japanese' translation for Twenty Fifteen 1.5...
143+
Downloading translation from https://downloads.wordpress.org/translation/theme/twentyfifteen/1.5/ja.zip...
144+
Translation updated successfully.
145+
Success: Updated 2/2 translations.
146+
147+
## Installing
148+
149+
Installing this package requires WP-CLI v0.23.0 or greater. Update to the latest stable release with `wp cli update`.
150+
151+
Once you've done so, you can install this package with `wp package install wp-cli/language-command`.
152+
153+
## Contributing
154+
155+
We appreciate you taking the initiative to contribute to this project.
156+
157+
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.
158+
159+
### Reporting a bug
160+
161+
Think you’ve found a bug? We’d love for you to help us get it fixed.
162+
163+
Before you create a new issue, you should [search existing issues](https://github.com/wp-cli/language-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.
164+
165+
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/wp-cli/language-command/issues/new) with the following:
166+
167+
1. What you were doing (e.g. "When I run `wp post list`").
168+
2. What you saw (e.g. "I see a fatal about a class being undefined.").
169+
3. What you expected to see (e.g. "I expected to see the list of posts.")
170+
171+
Include as much detail as you can, and clear steps to reproduce if possible.
172+
173+
### Creating a pull request
174+
175+
Want to contribute a new feature? Please first [open a new issue](https://github.com/wp-cli/language-command/issues/new) to discuss whether the feature is a good fit for the project.
176+
177+
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:
178+
179+
1. Create a feature branch for each contribution.
180+
2. Submit your pull request early for feedback.
181+
3. Include functional tests with your changes. [Read the WP-CLI documentation](https://wp-cli.org/docs/pull-requests/#functional-tests) for an introduction.
182+
4. Follow the [WordPress Coding Standards](http://make.wordpress.org/core/handbook/coding-standards/).
183+
184+
185+
*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.*

composer.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,11 @@
3232
"dev-master": "1.x-dev"
3333
},
3434
"commands": [
35-
"core language add",
36-
"core language list",
37-
"core language remove"
35+
"language core activate",
36+
"language core install",
37+
"language core list",
38+
"language core uninstall",
39+
"language core update"
3840
]
3941
}
4042
}

0 commit comments

Comments
 (0)