Whenever I'm writing this blog, I convert all of my images to WebP. Gnome however, my desktop environment, happens to be lacking in terms of WebP support. Here's a couple tricks to reduce the friction on Gnome 48.
Thumbnail generation
Gnome does not support WebP thumbnailing natively, but it does support creating custom thumbnailers. Calico Cat's response on StackExchange provides an comprehensive guide on how to do it for WebP.
However, if you're on Arch Linux (or derivative), simply install the webp-pixbuf-loader package instead.
Convert to WebP from Nautilus
Nautilus file dialogs can be easily extended with custom scripts. Here's a script that will convert all of the selected images to WebP:
#!/usr/bin/env bash
# Located at ~/.local/share/nautilus/scripts/convert-to-webp.sh
# Requires libwebp (provides cwebp)
while IFS= read -r PATH_INPUT; do
PATH_DIR_PARENT="$(dirname "${PATH_INPUT}")"
NAME_NO_EXT=$(basename "$PATH_INPUT" | cut -d. -f1)
PATH_OUTPUT="${PATH_DIR_PARENT}/${NAME_NO_EXT}.webp"
cwebp "${PATH_INPUT}" -o "${PATH_OUTPUT}"
done <<<"${NAUTILUS_SCRIPT_SELECTED_FILE_PATHS}"
Note that this does not recurse into directories.
In case you prefer ImageMagick:
9c9
< cwebp "${PATH_INPUT}" -o "${PATH_OUTPUT}"
---
> convert "${PATH_INPUT}" "${PATH_OUTPUT}"
Now you'll get this dialog under right-click → Scripts: