Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Image attachments: use full-resolution file if available (#87)
* Image attachments: use full-resolution file if available Images embedded in posts/pages may sometimes use downscaled image thumbnails or thumbnails sizes that don't exist anymore, patterned like `some-file-1920x1080.jpg`. We try to find the full-resolution image if any, like `some-file.jpg`, then fall-back to whatever URL was given in content if this failed. This assumes Hugo image partials will handle resizing to theme width and responsive image sizes internally (see https://discourse.gohugo.io/t/hugo-image-processing-and-responsive-images/43110/4). * Update output file path too if full-res image was found * Add log lines, refine media retrieving logic * Fix Go formatting
- Loading branch information