1 --- WindowMaker-0.80.2/util/wmchlocale.in.orig Tue Jul 24 01:13:24 2001
2 +++ WindowMaker-0.80.2/util/wmchlocale.in Sat Nov 23 14:26:30 2002
6 if [ -z "$new_locale" ]; then
10 echo -e "\nUnrecognized command line argument, run without arguments to see help.\n"
15 if [ -n "$auto" ] && [ -z "$new_locale" ]; then
17 + new_locale=${LANG%_*}
18 if [ -z "$new_locale" ]; then
19 new_locale="${LC_ALL%_*}"
22 if [ -z "$default" ]; then
23 echo -e "\nNo locale is set, using default...\n" >/dev/stderr
25 -elif ! (locale -a |grep "^$new_locale$" &>/dev/null); then
26 +elif ! (locale -a |grep "^$new_locale$" >/dev/null 2>/dev/null); then
27 if [ -z "$auto" ]; then
29 "Locale $new_locale is not supported on your system..."\
31 "Check your LANG and LC_ALL variables or install your locale support\n"\
35 +# exit 1 -- disabled, `locale -a` doesn't work under glibc 2.3.1
38 echo -n "Setting Window Maker root menu... "
40 for new_menu in $menu_list; do
41 for wm_dir in $LOCALDIR $GLOBALDIR; do
42 if [ -f "$wm_dir/$new_menu" ]; then
43 - if [ -z "$new_locale" ] || ( [ -n "$new_locale" ] && echo "$new_menu" |grep "menu.$new_locale" &>/dev/null ); then
44 + if [ -z "$new_locale" ] || ( [ -n "$new_locale" ] && echo "$new_menu" |grep "menu.$new_locale" >/dev/null 2>/dev/null); then
47 echo "fail (copying default)"
50 args="--locale=$new_locale $nodef"
52 -if wsetfont "$args" &>/dev/null; then
53 +if wsetfont "$args" >/dev/null 2>/dev/null; then
57 - if wsetfont default "$test" &>/dev/null; then
58 + if wsetfont default "$test" >/dev/null 2>/dev/null; then
59 echo " (setting default)"