Add "xdg-mime query fileencoding"
Submitted by Reuben Thomas
Assigned to Jonathan Blandford Blandford @jrb
Description
/usr/bin/file can guess the encoding of a file. I haven't looked, but perhaps some of the other detectors used by xdg-mime can too?
Supporting this command via /usr/bin/file is as simple as passing --mime-encoding rather than --mime-type to file. Then one could use
xdg-mime query fileencoding foo.bar
to try to get the encoding of a file.