openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 60d074961c86ddc6f6886e5a010509f1adc73e7a
parent dc788cd7f7806d4f10bdd79a0761fa8754050716
Author: dankert <devnull@localhost>
Date:   Wed,  2 Nov 2005 22:14:12 +0100

Vergleichen von Sprachdateien auf fehlende Inhalte

Diffstat:
doc/examples/maintenance/compare-lang.sh | 36++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+), 0 deletions(-)

diff --git a/doc/examples/maintenance/compare-lang.sh b/doc/examples/maintenance/compare-lang.sh @@ -0,0 +1,36 @@ +#!/bin/sh +# Sorting the language file in alphabetic order + +if [ ! -f $1 ]; then + echo "" + echo "usage: $0 <filename> <filename>" + echo "" + echo "This script prints out the language element of file 1 which are not in file 2." + echo "" + exit +fi + +if [ ! -r $1 ]; then + echo "$1 is not readable" + exit +fi + +if [ ! -r $2 ]; then + echo "$2 is not readable" + exit +fi + +cat $1|egrep "^;" -v|while read line +do + #echo "Zeile:" + anfline=`echo $line|sed s/=.*/=/` + #echo "$anfline" # Output the line itself. + #echo Hat `cat $2|grep "$anfline"` + if [ "`cat $2|grep \"$anfline\"`" == "" ]; then + echo $line + #echo ";not in $2: $anfline" + fi + +done + +