#!/bin/sh
#
# Copyright 2001 Sun Microsystems, Inc.
#
#ident	"@(#)getLocale.sh	1.1	01/08/29 SMI"
#
# This script asks the user which locale/language to run in
#

# where to put the env variables
LOCFILE=$1

#
# Initialize the locale information in /tmp/root/etc/default/init,
# and set the LANG variable accordingly. From this point on all
# messages and executable should be running internationalized.
SYSIDNET="/usr/sbin/sysidnet -l -y"
if [ ! -f /tmp/.manual-sysid ] ; then
	eval "$SYSIDNET"
else
	echo "Would have run $SYSIDNET"
	/sbin/sh
fi

grep '^LANG=' /etc/default/init >> $LOCFILE
grep '^LC_.*=' /etc/default/init >> $LOCFILE
