Ability to Exclude Revisions from `wp db search`
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
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.
Written by the indexing model from the issue text.
Description
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.
- Dominant language
- PHP
- Stars
- 76
- Forks
- 73
- Avg merge
- 9h 31m
- Merged PRs (30d)
- 2
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from wp-cli/db-command
-
command:db-size scope:documentation
Difficulty 3/5 1-2 days Newbie friendliness 65/100
wp-cli/db-command#348 · 1 comment ·
-
bug command:db-query
wp-cli/db-command#319 · 5 comments · 1 reaction · 2 assignees ·
-
command:db scope:distribution state:unconfirmed
wp-cli/db-command#306 · 5 comments · 1 reaction · 2 assignees ·
-
bug command:db-export
Difficulty 3/5 1-2 days Newbie friendliness 45/100
wp-cli/db-command#289 · 2 comments ·
-
command:db-export command:db-import scope:distribution state:unconfirmed
Difficulty 5/5 Over a week Newbie friendliness 25/100
wp-cli/db-command#327 · 8 comments · 2 reactions ·
All issues in wp-cli/db-command
Similar issues
-
a11y admissions.uiowa.edu needs grooming SiteImprove best practice
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
Save States Menu Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
pluginsGLPI/datainjection#673 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
octobercms/october#6130 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
getgrav/grav-plugin-form#656 ·