-
Notifications
You must be signed in to change notification settings - Fork 77
[Feature Request] Only optimized changed images #92
Description
Thank you for creating this well-documented action! 🙌
Also, please forgive me if I missed any documentation or settings that would solve what I'm requesting. 😅
What problem would this feature solve?
It looks like this action will optimize all images in the repo that match any selected paths. If that is true, I'd love the ability to be able to only optimize images that are part of the commit that triggered the workflow. This would speed up a potentially long process and target only changed images.
We have a very large directory of images that takes up to 5 hours to compress, but if we know that the existing images are already compressed, it'd be great to only optimize images that are added or updated.
Describe the solution you’d like to see
An input parameter that allows you to select targeting only images that are part of the commit that triggered the workflow. This would likely only be applicable to pull_request and push events.
If the input parameter is set, the action would retrieve the list of changed files and find any image files. If there are changed image files, those images will be compressed.