-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Offer flag to update post content when regenerating thumbnails #121
Comments
I noticed today that
Perhaps it would be relatively straightforward to bring update_usages_in_posts() into WP CLI for feature parity. Otherwise, it could help future users expecting this step to happen if the WP CLI docs and command usage info explicitly noted that post content will not be updated. Edited to add: I see on closer reading that the content update functionality in Regenerate Thumbnails has been disabled, so makes more sense that this is not in the CLI command either. |
This is the same issue as the one here: the bug seems to occur when invoking the i can confirm that running the command |
Steps to reproduce.
Solution 1. We have the old file name. Before the image is regenerated the old size is stored in the Questions.
Solution 2.
This way every user can loop over this output themselves and the questions for Solution 1 can be implemented freely based on every usecase. |
I removed the We're fixing the missing metadata bug with #130 |
Describe the current, buggy behavior
I’m using
wp-cli 2.4.0
. I recently built a client a new theme and updated the large image size to fit their new theme. I then ran the commandwp media regenerate --image_size=large --only-missing
to regenerate new large thumbnails. Everything worked as planned. All new images were created, the old were removed, however none of the posts were updated with the new image size. They were all referencing the old images even though they no longer existsDescribe how other contributors can replicate this bug
Update large image size in
settings > media
run command
wp media regenerate --image_size=large --only-missing
Describe what you would expect as the correct outcome
The command would go through all images and regenerate the large image size to the new image size. It should delete the old images and update the posts to which those images were attached with the new image size.
Let us know what environment you are running this on
Dev, Staging, Production
The text was updated successfully, but these errors were encountered: