Get file encoding via Linux shell

To find out which encoding a certain file has, you can use the file command on Linux shell:

$> file -i path_to_encoded_file.ending

Output example:

path_to_encoded_file.ending: text/plain; charset=iso-8859-1

 

Leave a Reply

Your email address will not be published. Required fields are marked *

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.