Date: Fri, 18 Feb 2011 15:13:08 +0000 (UTC) From: Josh Paetzel <jpaetzel@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r218802 - head/usr.sbin/pc-sysinstall/backend-query Message-ID: <201102181513.p1IFD8tR062191@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jpaetzel Date: Fri Feb 18 15:13:07 2011 New Revision: 218802 URL: http://svn.freebsd.org/changeset/base/218802 Log: Sort available keyboard layouts to a more sane default. PR: bin/154687 Submitted by: kmoore Approved by: kib (mentor, implicit) Modified: head/usr.sbin/pc-sysinstall/backend-query/xkeyboard-layouts.sh Modified: head/usr.sbin/pc-sysinstall/backend-query/xkeyboard-layouts.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend-query/xkeyboard-layouts.sh Fri Feb 18 15:06:35 2011 (r218801) +++ head/usr.sbin/pc-sysinstall/backend-query/xkeyboard-layouts.sh Fri Feb 18 15:13:07 2011 (r218802) @@ -26,6 +26,12 @@ # $FreeBSD$ FOUND="0" +TMPLIST="/tmp/.xkeyList.$$" +XLST="/usr/local/share/X11/xkb/rules/xorg.lst" + +if [ ! -e "${XLST}" ] ; then + exit 1 +fi # Lets parse the xorg.list file, and see what layouts are supported while read line @@ -36,9 +42,9 @@ do echo $line | grep '! ' >/dev/null 2>/dev/null if [ "$?" = "0" ] then - exit 0 + break else - echo "$line" + echo "$line" >> ${TMPLIST} fi fi @@ -51,6 +57,13 @@ do fi fi -done < /usr/local/share/X11/xkb/rules/xorg.lst +done < $XLST + +# Display the output, with us English as the first entry +echo "us U.S. English" +sort -b -d +1 $TMPLIST + +# Delete the tmp file +rm $TMPLIST exit 0
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201102181513.p1IFD8tR062191>