Ability to Exclude Revisions from `wp db search`

オープン
#156 コメント 1 件 リアクション 20 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
mariadb, mysql, php
領域
cli, database

調査の方向性

Start at the wp db search command entry point and trace how its options and database search are defined. Review the existing command tests and documentation, if available; done means an --exclude-revisions option works and matching revision records are omitted from results.

索引モデルが issue の本文から書いたものです。

説明

command:db command:db-search

Describe your use case and the problem you are facing

I often use wp db search to determine if a certain shortcode, class, etc. is in use. These search results include revisions, so it's possible that a search with 10 results only represents a single post. This makes the function significantly less useful for what feels like a pretty simple use case.

Describe the solution you'd like

The simplest solution would be some type of standalone flag so I could do something like wp db search 'string' --exclude-revisions.

My only hesitancy in suggesting this is wondering whether some more generalized way to include or exclude other things would be useful. On the flipside, a super powerful way to limit the search query would probably end up being much less user-friendly.

主要言語
PHP
スター
76
フォーク
73
平均マージ
9時間 31分
マージ済み PR(30日)
2

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

wp-cli/db-command のほかの issue

wp-cli/db-command の issue をすべて見る

似ている issue

PHP の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。