Mercurial > mplayer.hg
annotate help/help_diff.sh @ 8134:63364178ff56
divx_vbr.c now GPL, small parts rephrased.
author | diego |
---|---|
date | Sat, 09 Nov 2002 02:22:19 +0000 |
parents | 32c7ca9359b1 |
children | 6973e76d95b2 |
rev | line source |
---|---|
6356
b54d7fd6471a
This script has no bash specific stuff, it's all standard bourne shell, so execute with sh.
atmos4
parents:
6288
diff
changeset
|
1 #! /bin/sh |
6285
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
2 |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
3 # This script walks through the master (stdin) help/message file, and |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
4 # prints (stdout) only those messages which are missing from the help |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
5 # file given as parameter ($1). |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
6 # |
6288 | 7 # Example: help_diff.sh help_mp-hu.h < help_mp-en.h > missing.h |
6285
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
8 |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
9 curr="x" |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
10 |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
11 while read -r line ; do |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
12 |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
13 if ( echo $line | cut -d ' ' -f 1 | grep '^#define' > /dev/null ); then |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
14 curr=`echo $line | cut -d ' ' -f 2` |
6288 | 15 if ( grep " $curr " $1 > /dev/null ); then |
6285
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
16 curr="x" |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
17 fi |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
18 else |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
19 if test x"$line" = x; then |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
20 curr="x" |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
21 fi |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
22 fi |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
23 |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
24 if test $curr != "x" ; then |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
25 echo "$line" |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
26 fi |
0b73c83bc47f
automatically adding untranslated messages to help_mp.h from english master file
arpi
parents:
diff
changeset
|
27 |
6286 | 28 done |
6356
b54d7fd6471a
This script has no bash specific stuff, it's all standard bourne shell, so execute with sh.
atmos4
parents:
6288
diff
changeset
|
29 |