[PC-BSD Commits] r5138 - pcbsd/trunk/pc-sysinstall/backend-query

svn at pcbsd.org svn at pcbsd.org
Tue Nov 24 12:27:39 PST 2009


Author: kris
Date: 2009-11-24 12:27:39 -0800 (Tue, 24 Nov 2009)
New Revision: 5138

Modified:
   pcbsd/trunk/pc-sysinstall/backend-query/list-tzones.sh
Log:

Sort our timezone listing, make it easy on the user ;)



Modified: pcbsd/trunk/pc-sysinstall/backend-query/list-tzones.sh
===================================================================
--- pcbsd/trunk/pc-sysinstall/backend-query/list-tzones.sh	2009-11-24 20:19:55 UTC (rev 5137)
+++ pcbsd/trunk/pc-sysinstall/backend-query/list-tzones.sh	2009-11-24 20:27:39 UTC (rev 5138)
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-FOUND="0"
+rm ${TMPDIR}/.tzonetmp >/dev/null 2>/dev/null
 
 # Backend script which lists all the available timezones for front-ends to display
 while read line
@@ -8,8 +8,11 @@
   echo "$line" | grep "^#" >/dev/null 2>/dev/null
   if [ "$?" != "0" ]
   then
-    echo "$line" |  tr -s "\t" ":" | cut -d ":" -f 3-4
+    echo "$line" |  tr -s "\t" ":" | cut -d ":" -f 3-4 >>${TMPDIR}/.tzonetmp
   fi
 done < /usr/share/zoneinfo/zone.tab
 
+sort ${TMPDIR}/.tzonetmp
+rm ${TMPDIR}/.tzonetmp >/dev/null 2>/dev/null
+
 exit 0



More information about the Commits mailing list