Catatan Rilis WP-CLI v2.0.0


This is a big one! 67 awesome contributors have collaborated over 364 pull requests to bring you WP-CLIWP-CLI WP-CLI is the Command Line Interface for WordPress, used to do administrative and development tasks in a programmatic way. The project page is http://wp-cli.org/ https://make.wordpress.org/cli/ v2!

Before going over the detailed change log, let’s discuss a few key areas of this update in more detail. There’s also a “Breaking changes” further down in the document.

“Framework” & “Bundle” are now two separate packages

This is the main change we planned to include with version 2 of WP-CLI. From v2 onwards, the “framework” is a separate package from the “bundle” that is used to build the Phar file you can download. The framework is now contained within the wp-cli/wp-cli package, while the bundling has moved on to the wp-cli/wp-cli-bundle.

Agreed, this does not sound like such a big deal, but in terms of development experience and maintenance effort, it is a tremendous improvement, making almost every future change faster and simpler.

What does that mean for users working with the Phar version of WP-CLI ?

Nothing much, really. Apart from some of the debugging information containing different paths, you won’t see much of a difference. One of the goals was to not disrupt current usage more than necessary. If you only ever download the WP-CLI Phar and use that to control your sites, you should not need to care about this change.

What does this mean for site owners using WP-CLI through Composer ?

They will rejoice! The framework itself has gotten rid of most of its problematic dependencies. If you compare the dependencies of v1.5.1 with those of v2.0.0, you’ll see that the list is drastically shorter. Also, the most problematic set of the dependencies, the hard requirement on an old version of Symfony, is gone. The only Symfony component we still have (yet) is symfony/finder, as there’s no upper version limit for that one.

Most of the more problematic dependencies actually came from the WP-CLI package manager (wp-cli/package-command). That command is not only optional now, there’s also no valid reason to use it at all when pulling WP-CLI in via Composer directly.

This also means that you will not see WP-CLI automatically pull in all bundled commands automatically. Let’s say, you need the wp-cli/db-command for some maintenance tasks for your site. With v1.5.1, this would have pulled in the entire WP-CLI bundle as a dependency. With v2.0.0, it will only pull in the lean framework as a dependency, nothing more. You’ll end up with a WP-CLI active on your site that contains the commands clihelp (as the two “built-ins”) and db.

As a nice side-benefit, this makes WP-CLI run much faster in such scenarios, as it only loads what is effectively needed for the site. The difference might not seem like much, but depending on how you use in in your scripts, it can make a big difference.

What does this mean for developers working on third-party WP-CLI commands?

Splitting everything up has provided a few additional perks for developers (see also the next section about the testing improvements). Everything is leaner, and the dependency resolutions are less problematic, as we got rid of that one nasty circular dependency (command requires framework => framework equals bundle => bundle requires command).

However, dependency declarations need to be more explicit now. If you require wp-cli/wp-cli, this will only provide the pure framework. You cannot implicitly rely on any of the bundled commands in that case, you’ll have to explicitly require any additional command you might need.

Testing framework is now a separate package

One of the things that bothered me a lot while maintaining WP-CLI was the fact that the testing infrastructure was “scaffolded” into the individual command packages (just as it is into the third-party commands). This basically means that we copy-pasted the code in there, and if the code needs to change (because of a bug being fixed or an improvement being made), we have to create changes in every single package to overwrite the copy-pasted version of the testing code with an updated one.

Now we have the testing infrastructure abstracted away into a separate package: wp-cli/wp-cli-tests. For this first iteration, it includes out-of-the-box support for PHPPHP PHP (recursive acronym for PHP: Hypertext Preprocessor) is a widely-used open source general-purpose scripting language that is especially suited for web development and can be embedded into HTML. https://www.php.net/manual/en/index.php linting, PHP Code SnifferPHP Code Sniffer PHP Code Sniffer, a popular tool for analyzing code quality. The WordPress Coding Standards rely on PHPCS. checks (including the WordPress Coding StandardsWordPress Coding Standards The Accessibility, PHP, JavaScript, CSS, HTML, etc. coding standards as published in the WordPress Coding Standards Handbook.
May also refer to The collection of PHP_CodeSniffer rules (sniffs) used to format and validate PHP code developed for WordPress according to the PHP coding standards.
and the PHP Compatibility Checks), PHPUnit unit tests and Behat functional tests. They are set up in such a way that they detect whether they should run, based on config files or test files presence.

A simple composer test will run all of the tests in order. But you can also run them individually, through composer lint|phpcs|phpunit|behat. Adding further configuration flags can be done as well, but you need to remember to prepend them with a double-dash ( --) first, otherwise the arguments will be interpreted by Composer itself.

For the most important tests, the functional Behat tests, you can also define some constants to adapt the environment in which to test. For example, testing against a specific version of WordPress can be done by providing the WP_VERSION constant: WP_VERSION=4.2 composer behat. This constant also understands latest and trunk correctly.

In general, the tests are set up in such a way that you’ll face less differences between what you get locally and what you’ll get inside of the Travis CI checks.

And given that the tests can now be worked on in one central location, we’re already thinking about what our next steps are to further improve them, like letting you easily re-run only the failed scenarios from last run or automatically retrying failures on Travis to make sure it was not a random intermittent timeout or similar.

New command: i18n make-pot

@swissspidy has spent countless hours working on a new command that has now finally made it into the official WP-CLI bundle. We now introduce you to the i18n command family and its first usable subcommand, i18n make-pot.

What started out as an exploration at first is now a robust tool that is already being used in production systems and is even planned to replace the default translation tool bundled with WordPress Core. It supports both PHP and JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser.
https://www.javascript.com
, can manipulate and put into shape multiple files and even detected bugs in the original CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. tooling.

This can now easily be including in whatever automated tooling you use for your site/pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party./theme development, and should make your translation work much smoother. Here’s a quick rundown of the main features:

  • Automatically detects plugins and themes and extracts file headers.
  • Allows extraction of only a specific text domain.
  • Supports JavaScript string extraction, even for JSX and ESNext.
  • Allows merging the resulting POT file with an existing one, e.g. one created by Babel.
  • Powerful rules to include/exclude specific directories (minified JS files, vendor, .git folder, etc.).
  • Supports extracting strings from WordPress core the same way it’s done today with 4 different projects. See https://github.com/wp-cli/i18n-command/pull/69 for examples.
  • Can warn about strings with wrong placeholders, as well as misleading or missing translator comments. This could be very useful for core but also plugin/developers to improve polyglots UXUX UX is an acronym for User Experience – the way the user uses the UI. Think ‘what they are doing’ and less about how they do it..

A big shoutout to @swissspidy for the fabulous work he did on that command!

Minor Framework enhancements

New WordPress action: 'cli_init'

We introduced a new action 'cli_init' that will be triggered by WP-CLI during the 'plugins_loaded' action. This can be used as a conditional trigger for loading WP_CLI specific code, in case you don’t want to use the constants we already provide, for whatever reason.

This being a WordPress action, it adds a bit more flexibility to the process of loading a WP-CLI command, like for example one plugin being able to unhook the commands of another plugin.

New command: config edit

Easily open your wp-config.php in your favorite editor (configured through the EDITOR environment variable). Once you save within that editor, the wp-config.php will be correctly updated.

Note: This works through SSHSSH Secure SHell – a protocol for securely connecting to a remote system in addition to or in place of a password./vagrant/docker tunnels as well, but keep in mind that it will use the EDITOR of the remote system, which should be something like vim (=> “how to exit the vim editor” 😉).

# Launch system editor to edit wp-config.php file
$ wp config edit

# Edit wp-config.php file in a specific editor
$ EDITOR=vim wp config edit

New command: config shuffle-salts

This refreshes the salts stored in your wp-config.php file, which are cryptographic values used for authentication and other security-related functionality. Regulary refreshing these salts could be considered “security hygiene” for a site.

The command will generate the salts locally if your PHP server environment is cryptographically secure enough to do so, and falls back to the remote wordpress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/ APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. endpoint if not.

# Get new salts for your wp-config.php file
$ wp config shuffle-salts
Success: Shuffled the salt keys.

New command: db columns

Get a tabular view of the table schema for a given table. It shows you how the individual columns of the table have been defined, which default values they use and what extra functionality might be attached to them.

$ wp db columns wp_posts
+-----------------------+---------------------+------+-----+---------------------+----------------+
|         Field         |        Type         | Null | Key |       Default       |     Extra      |
+-----------------------+---------------------+------+-----+---------------------+----------------+
| ID                    | bigint(20) unsigned | NO   | PRI |                     | auto_increment |
| post_author           | bigint(20) unsigned | NO   | MUL | 0                   |                |
| post_date             | datetime            | NO   |     | 0000-00-00 00:00:00 |                |
| post_date_gmt         | datetime            | NO   |     | 0000-00-00 00:00:00 |                |
| post_content          | longtext            | NO   |     |                     |                |
| post_title            | text                | NO   |     |                     |                |
| post_excerpt          | text                | NO   |     |                     |                |
| post_status           | varchar(20)         | NO   |     | publish             |                |
| comment_status        | varchar(20)         | NO   |     | open                |                |
| ping_status           | varchar(20)         | NO   |     | open                |                |
| post_password         | varchar(255)        | NO   |     |                     |                |
| post_name             | varchar(200)        | NO   | MUL |                     |                |
| to_ping               | text                | NO   |     |                     |                |
| pinged                | text                | NO   |     |                     |                |
| post_modified         | datetime            | NO   |     | 0000-00-00 00:00:00 |                |
| post_modified_gmt     | datetime            | NO   |     | 0000-00-00 00:00:00 |                |
| post_content_filtered | longtext            | NO   |     |                     |                |
| post_parent           | bigint(20) unsigned | NO   | MUL | 0                   |                |
| guid                  | varchar(255)        | NO   |     |                     |                |
| menu_order            | int(11)             | NO   |     | 0                   |                |
| post_type             | varchar(20)         | NO   | MUL | post                |                |
| post_mime_type        | varchar(100)        | NO   |     |                     |                |
| comment_count         | bigint(20)          | NO   |     | 0                   |                |
+-----------------------+---------------------+------+-----+---------------------+----------------+

New command: db clean

We already had db reset, but that dropped the entire database… which is not a nice thing to do if there’s more than a default WordPress site in there 😱!

The new db clean will only drop the tables that are actually part of the current WordPress installation and leave the rest of the database instance intact.

# Delete all tables that match the current site prefix.
$ wp db clean --yes
Success: Tables dropped.

New command: site meta

We’ve added CRUD methods adddeletegetlistpatch, pluck and update for the “site metaMeta Meta is a term that refers to the inside workings of a group. For us, this is the team that works on internal WordPress sites like WordCamp Central and Make WordPress.” entities.

Oh, and while you are wondering… Yes, you are right, WordPress does not have “site meta” entities. But we didn’t lose our minds: WordPress will introduce “site meta”, together with a wp_site_meta table, with its 5.0 version. We just like to be prepared, that’s all… 😜

# Set site meta
$ wp site meta set 123 bio "Mary is a WordPress developer."
Success: Updated custom field 'bio'.

# Get site meta
$ wp site meta get 123 bio
Mary is a WordPress developer.

# Update site meta
$ wp site meta update 123 bio "Mary is an awesome WordPress developer."
Success: Updated custom field 'bio'.

# Delete site meta
$ wp site meta delete 123 bio
Success: Deleted custom field.

New command: user check-password

You can now let WordPress tell you whether a given password is valid for a specific user. This is NOT an endorsement to build your authentication layer with Bash scripts! But who knows what exotic automation needs the DevOps folks will come up with…

The command will let you know through a shell exit code whether the password was valid or not, so you can use it directly in if conditionals.

# Check whether given credentials are valid; exit status 0 if valid, otherwise 1
$ wp user check-password admin adminpass
$ echo $?
1

# Bash script for checking whether given credentials are valid or not
if ! $(wp user check-password $USER $PASSWORD); then
    notify-send "Invalid Credentials";
fi

New commands: language plugin and language theme

They both come with the following subcommands: install, update, uninstall, list and is-installed (which was added to core language as well).

You can now fully control all of the language files of your installation individually.

# Install the Dutch theme language pack.
$ wp language plugin install hello-dolly nl_NL
Success: Language installed.

# Uninstall the Dutch theme language pack.
$ wp language plugin uninstall hello-dolly nl_NL
Success: Language uninstalled.

# List installed theme language packages.
$ wp language plugin list --status=installed
+----------+--------------+-------------+-----------+-----------+---------------------+
| language | english_name | native_name | status | update | updated |
+----------+--------------+-------------+-----------+-----------+---------------------+
| nl_NL | Dutch | Nederlands | installed | available | 2016-05-13 08:12:50 |
+----------+--------------+-------------+-----------+-----------+---------------------+

Changes to existing command

  • db size now knows about ISO size units as well
  • option list got a new --unserialize flag
  • post generate can now deal with --post_date_gmt
  • user update now allows you to --skip-email
  • eval-file can read from STDIN
  • Both plugin uninstall and plugin delete can now act on --all plugins at once
  • cap list can now --show-grant
  • cap add , seeing what its list sibling had done, grew a new --grant flag
  • role list can now print a single --field=<field>
  • scaffold _s learned the new --woocommerce trick
  • search-replace lets you set a --regex-limit

Automated README.md updates

If you have ever contributed to WP-CLI and made a change to a command signature or documentation, you probably had me tell you that you needed to regenerate the README.md as well using the wp scaffold package-readme . --force command. No more!

We have now added a package wp-cli/regenerate-readme that automates this process. It adds both a precommit and a postcommit git hook that collaborate to transparently regenerate the README.md file behind the scenes and then amend your commit to add the required changes automatically.

This has not been deployedDeploy Launching code from a local development environment to the production web server, so that it’s available to visitors. to all command packages yet while we still experiment with some of the finer points of its implementation, but you’ll slowly see the annoying “please regenerate README.md kthxbye” reminders from my side disappear and become forgotten artifacts of the past.

Improved debug output

The debug output was always a bit sparse for WP-CLI. This is why we took the opportunity of v2 to improve upon it and make it more useful. It will now add debug messages for the hooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. that are triggered, or details about how commands are being loaded or deferred. This will be very useful for third-party command developers that ignore why their command is not properly registered.

We’ll make sure to add even more useful debugging information in the future.

Small side note: To make debugging work as early as possible, it is now smart enough to just store all messages until the logger it needs to send them to becomes available. This means you don’t need to worry about the timing here, if the WP_CLI exits for your code, the debugger is good to go!

Breaking changes

Here are a few things you need to be aware of when moving from ^v1 to ^v2:

  • An obvious breaking change is the bump to the minimum version of PHP. This will break for anyone trying to run WP-CLI on PHP 5.3.
  • The separation of the “framework” and the “bundle” into two separate packages will cause a breaking change if a third-party command is being pulled-in via Composer AND that third-party command relies on running bundled commands as well. This will seldom be the case and will be an easy fix. Installations using the Phar will not be impacted.
  • As many dependencies could be removed from the framework by not including the package manager automatically, any third-party command that relies on one of the removed Symfony packages or other dependencies AND hasn’t declared that requirement in its own Composer configuration will break. This will seldom be the case and will be an easy fix. Installations using the Phar will not be impacted as the package manager still comes with these requirements included.
  • The versions of some the dependencies will be bumped. If you happen to not lock WP-CLI into a specific version constraint, but do so for some of its dependencies, you might see a version constraint conflict when using Composer.
  • Any external code that relies on internal file structure, file naming or other internal details that are not part of the provided API could run the risk of breaking due to us moving things around from v1 to v2. This should hopefully not ever be the case, but you never know…
  • As a side-effect of adding the --all flag to plugin uninstall, a breaking change was introduced for consistency reasons. Whereas WP-CLI used to consider uninstalling a non-existent plugin as a “Success: Plugin already uninstalled”, it will now throw an error “Error: No plugin uninstalled”.
  • Kami telah berusaha sebaik mungkin untuk menghindari perubahan besar yang tidak perlu. Namun, dengan perubahan struktural besar seperti ini, masalah kecil dapat muncul dalam detailnya. Beri tahu kami jika Anda mengalami masalah lainnya!

Log perubahan lengkap

wp-cli/wp-cli-bundle

  • Bundel wp-cli/i18n-command [#9]

wp-cli/wp-cli

  • Tambahkan kelas Inflector dan fungsi praktis untuk membuat bentuk jamak kata benda [#4881]
  • Sesuaikan ekspresi reguler dalam pengujian make-phar agar melewati tautan wiki [#4873]
  • PHPCSPHP Code Sniffer PHP Code Sniffer, alat populer untuk menganalisis kualitas kode. WordPress Coding Standards bergantung pada PHPCS. Penyegaran Konfigurasi [#4867]
  • Perbaiki pemeriksaan versi PHP [#4864]
  • Picu hook 'cli_init' baru selama aksi WordPress 'plugins_loaded'. [#4861]
  • tambahkan templat untuk core-command ke phar [#4854]
  • Gunakan string lengkap sebagai fallback, bukan $mode, pada PHP < 7 [#4853]
  • Refaktorkan wp-cli/wp-cli agar hanya merepresentasikan framework, bukan bundel [#4851]
  • Hapus persyaratan WP 4.4 [#4845]
  • Perbaiki pengujian —skip-theme [#4843]
  • Perbaiki masalah skrip shell dalam ci/deploy.sh [#4842]
  • Perbaiki masalah skrip shell dalam bin/wp [#4841]
  • Tambahkan tanda kutip tambahan dalam ci/prepare.sh [#4840]
  • Kunci wp-completion.bash ke v1.5.1 [#4839]
  • Hapus lencana Gemnasium karena layanannya telah dihentikan [#4815]
  • Gunakan paket search-replace terbaru untuk memperbaiki pengujian yang rusak akibat perubahan kebijakan privasi [#4807]
  • Ubah 'latest' menjadi nomor versi [#4806]
  • Perbarui paket untuk memperbaiki pengujian yang rusak akibat WP5.0 [#4804]
  • Beralih ke perintah paket tetap [#4803]
  • Naikkan versi PHP terendah yang diuji ke 5.4 [#4798]
  • Tambahkan format output yang diterima yang hilang ke wp cli alias [#4765]
  • Tingkatkan deskripsi flag --skip-plugins dan --skip-themes [#4759]
  • Sertakan subtautan dalam README.md ke metode instalasi populer [#4756]
  • ABSPATH didefinisikan [#4743]
  • Lewati tabel wp_blogmeta untuk kompatibilitas mundur [#4736]
  • Perkenalkan fungsi \WP_CLI\Utils\normalize_path. Gunakan fungsi tersebut untuk konstanta ABSPATH. [#4718]
  • Batalkan @require-php-5.4 sementara yang hanya digunakan sekali dalam pengujian bootstrap. [#4716]
  • Kembalikan “Wajibkan PHP minimum 5.4” [#4715]
  • Lewati hook pre-commit dalam auto-composer-update [#4711]
  • Kembalikan “perbarui wp cli info” [#4702]
  • Hapus : dari pemeriksaan info pembaruan cli. [#4697]
  • Hanya periksa berkas yang dipentaskan selama verifikasi PHPCS pre-commit [#4696]
  • Domain kosong dalam pengujian framework setelah perubahan get_sites_by_path. [#4695]
  • Tambahkan uniq_id() saat mengekstrak berkas dari Phar [#4692]
  • Dukung peluncuran editor sistem dengan ekstensi berkas sementara tertentu [#4691]
  • Skrip untuk membuat hook GitGit Git adalah sistem kontrol versi terdistribusi gratis dan sumber terbuka yang dirancang untuk menangani segala hal, mulai dari proyek kecil hingga sangat besar, dengan kecepatan dan efisiensi. Git mudah dipelajari dan memiliki jejak penggunaan yang kecil dengan kinerja yang sangat cepat. Sebagian besar pengembangan plugin dan tema modern dilakukan menggunakan sistem kontrol versi ini.
    https://git-scm.com/
    pre-commit. [#4622]
  • Perbarui wp cli info [#4613]

wp-cli/handbook

  • Tambahkan dokumentasi tentang cara memecahkan masalah [#243]
  • Gunakan <example.com> sebagai placeholder [#242]
  • Perbaiki kesalahan ketik dalam <code-review.md> [#239] & [#241]
  • Hapus Tautan Mati [#238]
  • Perbarui dokumentasi untuk menginstal WP-CLI melalui brew [#236]
  • Tambahkan tanda kutip ke alias [#235]
  • Sesuaikan prosedur penandatanganan agar menggunakan kunci yang benar [#232]
  • Tambahkan perintah WP CLICLI Antarmuka Baris Perintah. Terminal (Bash) di Mac, Command Prompt di Windows, atau WP-CLI untuk WordPress. optimize dari Plugin WP-Optimize [#231]
  • Tambahkan perintah WP CLI updraftplus [#228]
  • Perbaiki tata bahasa dalam paragraf dokumentasi [#226]
  • Tambahkan berkas LICENSE ke repositori [#224]
  • Sertakan beberapa penyebutan strategis tentang repositori wp-cli/ideas [#223]
  • Hapus daftar keinginan dari situs web [#222]
  • Dokumentasikan WP_CLI_PHP_ARGS dalam dokumen konfigurasi WP-CLI [#221]
  • Sebutkan metode instalasi Docker [#220]
  • Dokumentasikan masalah pembuatan kiriman dengan karakter Latin dalam judul [#214]
  • Tambahkan BOM dalam wp-config.php sebagai masalah umum. [#212]
  • Tambahkan WP_CLI_PHP ke variabel lingkungan [#211]
  • Perbaiki tanda kutip yang hilang dalam dokumentasi [#210]
  • Pisahkan instalasi yang tidak dibundel; buat berdasarkan instans WP-CLI saat ini. [#207]
  • Perbarui hubungan Daniel dengan proyek [#206]

wp-cli/wp-cli.github.com

  • Perbarui <index.md> untuk bahasa Spanyol [#313]
  • Hapus lencana Gemnasium [#312]
  • Perbarui terjemahan pt_BR [#311]
  • Tambahkan berkas LICENSE ke repositori [#309]
  • Tambahkan catatan bahwa hanya versi bahasa Inggris yang digunakan sebagai sumber terjemahan [#308]
  • Terjemahkan beranda ke bahasa Spanyol [#307]
  • Ubah http menjadi https di semua tautan wp-cli.org. [#305]

wp-cli/autoload-splitter

  • Paket ini tidak lagi digunakan sejak v2.0.0

wp-cli/cache-command

  • Sesuaikan paket untuk framework v2 [#32]

wp-cli/checksum-command

  • Buat perubahan lunak lebih fleksibel untuk checksum plugin [#43]
  • Pemeriksaan perubahan lunak yang lebih fleksibel (masalah #34) [#41]
  • Tambahkan garis miring terbalik ke regex untuk mencocokkan jalur Windows dengan benar [#39]
  • Buat label GitHubGitHub GitHub adalah situs web yang menawarkan implementasi repositori git secara daring yang dapat dengan mudah dibagikan, disalin, dan dimodifikasi oleh pengembang lain. Repositori publik dapat dihosting secara gratis, sedangkan repositori privat memerlukan langganan berbayar. GitHub memperkenalkan konsep ‘pull request’, yaitu perubahan kode yang dibuat di cabang oleh kontributor dapat ditinjau dan didiskusikan sebelum digabungkan oleh pemilik repositori. https://github.com/ yang benar [#37]
  • Sesuaikan paket untuk framework v2 [#50]

wp-cli/config-command

  • Perbaiki versi pustaka ke ^1.2.1 [#53]
  • Hapus operasi remove() yang tersisa [#52]
  • Perkenalkan perintah config edit [#48]
  • Tambahkan nilai konfigurasi timeout yang lebih tinggi [#67]
  • Sesuaikan paket untuk framework v2 [#66]
  • Pastikan file_put_contents() menulis ke jalur wp-config.php [#63]
  • Tambahkan perintah shuffle-salts [#62]
  • Atur WP_CACHE_KEY_SALT [#59]

wp-cli/core-command

  • Pindahkan berkas templat dari wp-cli/wp-cli [#73]
  • Perbaiki jalur berkas templat mustache [#77] & [#78]
  • Bersihkan basis data di akhir instalasi untuk mencegah data duplikat [#76]
  • Sesuaikan paket untuk framework v2 [#81]

wp-cli/cron-command

  • Sesuaikan paket untuk framework v2 [#29]

wp-cli/db-command

  • Tambahkan perintah db columns [#100]
  • Hitung pengguna, bukan postingan, untuk pengujian smoke [#98]
  • Perbaiki kegagalan pengujian akibat diperkenalkannya tabel wp_blogmeta [#94]
  • Tambahkan perintah db clean [#93]
  • Tambahkan contoh untuk mengekspor postingan tertentu [#90]
  • Teruskan --column-statistics=0 ke perintah mysqldump [#105]
  • Tambahkan format ukuran ISO ke db size [#104]
  • Adaptasikan paket untuk framework v2 [#110]

wp-cli/embed-command

  • Adaptasikan paket untuk framework v2 [#38]
  • Buat perintah tingkat atas yang belum ada [#35]

wp-cli/entity-command

  • Perbaiki pengujian setelah Core memperkenalkan halaman “Kebijakan Privasi” bawaan [#177]
  • Abstraksikan CRUD meta ke dalam metode [#174]
  • Hapus argumen --user_email=<user-email> yang duplikatif [#173]
  • Ubah latest menjadi nomor versi sebenarnya [#171]
  • Tingkatkan pemformatan dokumentasi berbagai parameter format [#168]
  • Tambahkan subperintah site meta [#159]
  • Tambahkan flag --unserialize ke perintah option list [#156]
  • Tambahkan flag --from-post=<post_id> untuk membuat postingan duplikat [#154]
  • Kloning objek dengan benar untuk perbandingan [#152]
  • Perbaiki tanda kutip yang hilang dalam dokumentasi [#147]
  • Perbaiki jumlah daftar kategoriKategori Taksonomi ‘kategori’ memungkinkan Anda mengelompokkan postingan / konten yang memiliki keterkaitan umum. Kategori telah ditentukan sebelumnya dan mencakup cakupan yang luas. [#146]
  • Tambahkan subperintah user check-password [#144]
  • Ganti ‘install’ menjadi ‘installation.’ [#187]
  • Tambahkan dukungan untuk --post_date_gmt di post generate [#184]
  • Flag --skip-email opsional untuk wp user update [#155]
  • Adaptasikan paket untuk framework v2 [#192]

wp-cli/eval-command

  • Adaptasikan paket untuk framework v2 [#27]
  • Dukung eval-file dari STDIN (implementasi untuk #19) [#21]

wp-cli/export-command

  • Mulai dengan situs kosong untuk menghindari masalah jumlah [#36]
  • Adaptasikan paket untuk framework v2 [#44]

wp-cli/extension-command

  • Tambahkan template yang hilang ke repositori ini [#107]
  • Ganti tema yang sudah tidak digunakan dalam pengujian dengan tema baru [#105]
  • Perkenalkan theme mod list [#100]
  • Perbarui README.md dan rangkaian pengujian sebelum rilis v1.1.10. [#89]
  • Izinkan modern-wordpress redirect [#85]
  • Tambahkan flag --all untuk perintah plugin uninstall [#84]
  • Perbaiki jalur berkas mustache [#109] & [#112]
  • Cari: Tambahkan URLURL Alamat web tertentu dari situs web atau halaman web di Internet, seperti URL situs web www.wordpress.org plugin atau tema di <wordpress.org> [#108]
  • Tambahkan flag --all ke plugin delete [#103]
  • Adaptasikan paket untuk framework v2 [#116]

wp-cli/i18n-command

  • Persiapkan rilis v2 [#72]
  • Dukungan WordPress Core [#69]
  • Periksa kesalahan lainnya dalam string yang dapat diterjemahkan [#64]
  • Pisahkan ekstraksi terjemahan dari penulisan berkas Po [#63]
  • Jadikan PhpFunctionsScanner dapat diperluasDapat diperluas Ini adalah kemampuan untuk menambahkan fungsionalitas tambahan ke dalam kode. Plugin memperluas perangkat lunak inti WordPress. [#62]
  • Pisahkan penanganan argumen perintah dari __invoke() sebenarnya [#60]
  • Tambahkan parameter --headers [#58]
  • Tambahkan headerHeader Header situs Anda biasanya merupakan hal pertama yang dialami orang. Masthead atau karya seni header yang berada di bagian atas halaman Anda merupakan bagian dari tampilan dan nuansa situs web Anda. Header dapat memengaruhi opini pengunjung tentang konten Anda serta merek Anda/organisasi Anda. Tampilannya juga dapat berbeda pada ukuran layar yang berbeda. X-Generator ke berkas POT [#57]
  • Cetak beberapa pesan debug yang lebih membantu [#56]
  • Jadikan iterator direktori sebagai trait [#54]
  • Header domain teks [#43]
  • Tambahkan @when before_wp_load ke namespace perintah [#42]
  • Tambahkan opsi untuk mengekstrak string dengan domain teks apa pun [#38]
  • Teruskan opsi exclude dengan benar ke JsCodeExtractor [#37]
  • Tambahkan peringatan ketika sebuah string memiliki dua komentar penerjemah yang berbeda [#34]
  • Kecualikan beberapa direktori umum [#32]
  • Tambahkan kemampuan untuk menggabungkan dengan berkas POT yang sudah ada [#31]
  • Ekstraksi String JavaScript [#26]
  • Jangan mencoba mengekstrak apa pun ketika tidak ada berkas PHP [#24]
  • Tambahkan lebih banyak pengujian terkait komentar penerjemah [#23]
  • Standarkan nama berkas [#21]
  • Ekstrak semua fungsi yang didukung. [#13]

wp-cli/import-command

  • Adaptasikan pembuatan postingan/halaman agar tahan terhadap penambahan halaman kebijakan privasi [#25]
  • Adaptasikan paket untuk framework v2 [#30]

wp-cli/language-command

  • Kembalikan “Add plugin and theme command” [#28]
  • Adaptasikan paket untuk framework v2 [#43]
  • Gunakan download_url() dalam pemutakhir paket bahasa [#41]
  • Aktifkan pembaruan bahasa untuk plugin dan tema individual [#40]
  • Berikan peringatan jika tidak ada plugin atau tema yang ditentukan [#38]
  • Tambahkan perintah is-installed untuk memeriksa apakah bahasa tertentu telah terpasang [#36]
  • Perbarui pesan language core update --dry-run [#32]
  • Tambahkan perintah language plugin dan language theme. [#29]

wp-cli/media-command

  • Adaptasikan paket untuk framework v2 [#85]
  • Perbarui contoh dalam dokumentasi [#81]
  • Pulihkan instalasi ghostscript/imagick dan perbaiki nama bmp dalam pengujian regenerate. [#69]
  • Dokumentasikan cara mengambil URL lampiran setelah impor [#68]
  • Bersihkan cache objek WP secara berkala pada media regenerate/import. [#62]

wp-cli/package-command

  • Asumsikan nama paket bawaan jika berkas composer.json tidak dapat diambil [#78]
  • Hindari penggunaan bundel CA Composer jika berada dalam phar. [#73]
  • Pindahkan test-command ke organisasi Github wp-cli-test [#66]
  • Ekstrak sertifikat SSLSSL Secure Socket Layer – Enkripsi dari server ke browser dan sebaliknya. Mencegah pihak yang mengintip melihat apa yang Anda kirimkan antara browser dan server. dari Phar terlebih dahulu sebelum menggunakannya di Composer [#83]
  • Adaptasikan paket untuk framework v2 [#87]
  • Kecualikan versi Composer yang rusak [#91]

wp-cli/php-cli-tools

  • Hapus titik koma ganda [#130]
  • Perbaiki loopLoop Loop adalah kode PHP yang digunakan WordPress untuk menampilkan postingan. Dengan Loop, WordPress memproses setiap postingan yang akan ditampilkan di halaman saat ini, dan memformatnya sesuai dengan kecocokannya terhadap kriteria yang ditentukan dalam tag Loop. Kode HTML atau PHP apa pun dalam Loop akan diproses pada setiap postingan. https://codex.wordpress.org/The_Loop tak berujung yang mungkin terjadi dalam prompt() [#129]
  • Perbaiki kesalahan off-by-1 dalam contoh bilah kemajuan [#128]
  • Tambahkan parameter $msg opsional ke cli\Progress\Bar::tick() [#126]

wp-cli/rewrite-command

  • Adaptasikan paket untuk framework v2 [#20]

wp-cli/role-command

  • tambahkan argumen --show-grant ke wp cap list dan --grant ke wp cap add [#19]
  • Tambahkan dukungan --field=<field> untuk menampilkan daftar peran [#17]
  • Adaptasikan paket untuk framework v2 [#23]

wp-cli/scaffold-command

  • Lewati pengujian PHPUnit untuk PHP 7.2+ [#145]
  • Ubah scaffold block untuk membuat index.js [#142]
  • Perbaiki jalur khusus tema pada block yang dibuat dengan scaffold [#137]
  • Tambahkan PHP 7.2 ke templat CI [#135]
  • Kecualikan tests/test-sample.php melalui berkas phpunit.xml.dist [#134]
  • Perbaiki opsi sed -i pada MacOS [#132]
  • Gunakan default $WP_TESTS_DIR yang benar pada MacOS [#131]
  • Gunakan phpunit 6.5.6 untuk PHP 7.2 guna mengatasi ketidakcocokan pengujian core. [#125]
  • Perbaiki WPCSDukungan Komunitas WordPress Sebuah perusahaan manfaat publik dan anak perusahaan WordPress Foundation, yang didirikan pada tahun 2016. dalam pembuatan theme-tests [#121]
  • Alihkan templat CircleCI ke CircleCI 2.0. [#115]
  • Perbaiki label 'add_new_item' [#163]
  • Kecualikan string dari peringatan escape [#162]
  • Perbarui set aturan default PHPCS [#161]
  • Tambahkan flag --woocommerce ke perintah scaffold _s [#159]
  • Tambahkan sniff PHPCompatibilitysniff Modul untuk PHP Code Sniffer yang menganalisis kode untuk masalah tertentu. Beberapa sniff digabungkan untuk membuat standar PHPCS. Istilah ini dinamai demikian karena mendeteksi code smell, seperti anjing yang “mengendus” makanan. ke scaffold [#154]
  • Tambahkan escaping untuk judul blockBlock Block adalah istilah abstrak yang digunakan untuk mendeskripsikan unit markup yang, jika digabungkan, membentuk konten atau tata letak halaman web menggunakan editor WordPress. Gagasan ini menggabungkan konsep yang sebelumnya mungkin dicapai dengan shortcode, HTML khusus, dan penemuan embed ke dalam satu API serta pengalaman pengguna yang konsisten. [#153]
  • Hapus 'wp-blocks' dari dependensi style [#151]
  • Tambahkan pemeriksaan function_exists() ke templat PHP block [#147]
  • Adaptasikan paket untuk framework v2 [#166]

wp-cli/search-replace-command

  • Perbaiki pengujian yang rusak akibat penambahan halaman “Kebijakan Privasi” [#78]
  • Tangani serialisasi dan deserialisasi class yang tidak lengkap dengan baik [#76]
  • Tangani error PCRE dengan baik [#75]
  • Hapus pesan “Situs Tidak Ditemukan” dari penggunaan multisiteMultisite Multisite adalah fitur WordPress yang memungkinkan pengguna membuat jaringan situs dalam satu instalasi WordPress. Tersedia sejak WordPress versi 3.0, Multisite merupakan kelanjutan dari proyek WPMU atau WordPress Multiuser. Proyek WordPress MultiUser dihentikan dan fitur-fiturnya disertakan ke dalam core WordPress. Buku Pegangan Administrasi Lanjutan -> Membuat Jaringan. [#69]
  • Perbaiki pengujian GUID yang rusak [#81]
  • Tingkatkan logika --regex-limit [#70]
  • Adaptasikan paket untuk framework v2 [#86]
  • Tambahkan opsi --regex-limit. [#62]

wp-cli/server-command

  • Adaptasikan paket untuk framework v2 [#42]

wp-cli/shell-command

  • Adaptasikan paket untuk framework v2 [#25]
  • Jelaskan flag --basic dengan lebih baik [#23]

wp-cli/widget-command

  • Adaptasikan paket untuk framework v2 [#19]

Kontributor

Berikut daftar lengkap orang-orang luar biasa yang telah membantu mewujudkan ini:

@2020media, @abhijitrakas, @ajitbohra, @alpipego, @austinginder, @benlk, @BhargavBhandari90, @burhandodhy, @chesio, @CodeProKid, @danielbachhuber, @drzraf, @emirpprime, @ericgopak, @erlendeide, @felicianotech, @felipeelia, @fumikito, @GaryJones, @ghost, @gitlost, @greatislander, @JanVoracek, @janw-oostendorp, @javorszky, @jblz, @jmichaelward, @johnbillion, @josephfusco, @kirtangajjar, @kshaner, @lalaithan, @lf-jeremy, @libertamohamed, @marcovalloni, @marksabbath, @miya0001, @MoisesMN, @montu1996, @NicktheGeek, @ocean90, @pdaalder, @pekapl, @pixolin, @pjeby, @pmbaldha, @ptrkcsk, @ryanjbonnell, @sagarnasit, @salcode, @sasagar, @schlessera, @spacedmonkey, @spicecadet, @stevegrunwell, @strandtc, @svenkaptein, @swissspidy, @terriann, @thrijith, @tiagohillebrandt, @tomjn, @torounit, @wojsmol, @wp-make-coffee, @yousan, @zipofar

Terima kasih banyak kepada semua yang terlibat! ❤️

#rilis, #v2-0-0