diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/ChangeLog | 1 | ||||
-rwxr-xr-x | scripts/potomo | 10 |
2 files changed, 5 insertions, 6 deletions
diff --git a/scripts/ChangeLog b/scripts/ChangeLog index dacea163a..9b536bf61 100644 --- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -36,4 +36,3 @@ This file is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY, to the extent permitted by law; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - diff --git a/scripts/potomo b/scripts/potomo index 20617288e..b4c0a6b5c 100755 --- a/scripts/potomo +++ b/scripts/potomo @@ -43,18 +43,18 @@ if [ "$outfile" -nt "$infile" ]; then echo "potomo: '$outfile' is newer than source - keeping" 2>&1 exit 0 fi - + # Note that we could use the newer msgconv. However this tool was not # widely available back in 2008. fromset=`sed -n '/^"Content-Type:/ s/.*charset=\([a-zA-Z0-9_-]*\).*/\1/p' \ "$infile"` -case "$fromset" in - utf8|utf-8|UTF8|UTF-8) - echo "potomo: '$infile' keeping $fromset" >&2 +case "$fromset" in + utf8|utf-8|UTF8|UTF-8) + echo "potomo: '$infile' keeping $fromset" >&2 msgfmt --output-file="$outfile" "$infile" - ;; + ;; *) echo "potomo: '$infile' converting from $fromset to utf-8" >&2 iconv --silent --from-code=$fromset --to-code=utf-8 < "$infile" |\ |