#! /bin/sh
EXINIT0="set  autodetect=cn fileencoding=euc-cn displayencoding=euc-cn inputencoding=euc-cn noskipdisplay"
if [ -f ~/.exrc ]; then
	EXINIT="$EXINIT0 `sed -e '/^set /!d' -e 's/^set //' < ~/.exrc | tr '\012' ' '`"
else
	EXINIT=$EXINIT0
fi
export EXINIT
exec /usr/local/bin/nvi "$@"
