Check whether text files contain valid UTF-8. More information: https://joeyh.name/code/moreutils/.
isutf8 path/to/file1 path/to/file2 ...
isutf8 --verbose path/to/file1 path/to/file2 ...
stdout
, indicate the result merely with the exit code:isutf8 --quiet path/to/file1 path/to/file2 ...
isutf8 --list path/to/file1 path/to/file2 ...
--list
but inverted, i.e., only print the names of the files containing valid UTF-8:isutf8 --invert path/to/file1 path/to/file2 ...