I recently switched to GNOME 3 and was surprised to find that there was no way by which we could set the default applications. I am writing a Nautilus extension using Bash. I want to find the MIME type of a file.
Initially I used to extract the extension of the file using
sed and build the code on it. Then I realized that there is this command called
file. When I try to find the
mime-type of a
mkv file, the command
file --mime-type -b <filename> outputs
application/octet-stream but when I see the Nautilus properties window it shows the correct
Am I missing anything here? If not is there a better way in which I can file the mime-type of a file?