Add an `--all` flag to `wp comment delete`
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 35/100
Rechercherichtung
Start at the wp comment delete entry point and compare its behavior with wp plugin delete --all, wp theme delete --all, and wp site empty. Clarify the confirmation and --yes requirements before implementing; done means wp comment delete --all removes all comments safely, with the intended non-interactive behavior covered by tests.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Feature Request
- Yes, I reviewed the contribution guidelines.
Describe your use case and the problem you are facing
A website under my purview had hundreds of thousands of spam comments. It would be nice to be able to remove them in one fell swoop without having to resort to database queries (truncate wp_comments; truncate wp_commentmeta;).
Describe the solution you'd like
I'd like to add a flag to the wp comment delete subcommand:
wp comment delete --all
This may have a confirmation prompt along the lines of "Are you sure you want to delete XXXXX comments? (Y/n)" There might also be a "--yes" option for non-interactive use:
wp comment delete --all --yes
The addition of the "--all" flag would mirror similar-ish flags for the wp plugin delete --all and wp theme delete --all commands.
I'm aware that the wp site empty command also removes all comments, but this is a little bit different.
I'd be happy to take a stab at adding this modification, if approved.
- Vorherrschende Sprache
- PHP
- Sterne
- 105
- Forks
- 97
- Ø Merge
- 2 Std. 1 Min.
- Gemergte PRs (30 T.)
- 12
Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus wp-cli/entity-command
-
command:option command:option-update
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 35/100
wp-cli/entity-command#230 · 11 Kommentare · 1 Reaktion ·
-
command:post-meta-get command:post-meta-list
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
wp-cli/entity-command#142 · 10 Kommentare · 2 Reaktionen ·
Alle Issues in wp-cli/entity-command
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
getgrav/grav-plugin-api#45 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
RSS-Bridge/rss-bridge#5098 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
phingofficial/phing#2025 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
silverstripe/developer-docs#911 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100