]> gitweb.pimeys.fr Git - scripts-20-100.git/blob - reencode.sh
Raccourcis pour voir et corriger les droits foireux dans /usr/scripts
[scripts-20-100.git] / reencode.sh
1 #!/bin/bash
2
3 encoding=$(file "$1" | sed 's/.*: \([^ ]*\).*/\1/')
4 #echo $encoding
5
6 if [ "$encoding" = "assembler" ]
7 then
8 # recode iso8859-1..utf-8 "$1"
9 exit 0
10 fi
11
12 if [ "$encoding" != "UTF-8" ]
13 then
14 true
15 file "$1"
16 fi