[Lunar-commits] CVS: theedge/var/lib/lunar/menu mirrors.menu, 1.3,
1.4
Auke Kok
sofar at lunar-linux.org
Tue Mar 23 10:10:07 GMT 2004
Update of /var/cvs/lunar/theedge/var/lib/lunar/menu
In directory dbguin.lunar-linux.org:/tmp/cvs-serv3411/var/lib/lunar/menu
Modified Files:
mirrors.menu
Log Message:
Fixing mirror file and algorithm.... we don't need to make our lives so hard.
Index: mirrors.menu
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/menu/mirrors.menu,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- mirrors.menu 17 Mar 2004 22:58:11 -0000 1.3
+++ mirrors.menu 23 Mar 2004 10:10:05 -0000 1.4
@@ -17,18 +17,8 @@
# #
############################################################
-reverse() {
- while [ -n "$1" ]; do
- LOCATION=$1
- URL=$2
- echo "$URL"
- echo "$LOCATION"
- shift 2
- done
-}
-
mirror_list() {
- reverse `sort $MIRRORS/$1`
+ sort -r $MIRRORS/$1 | tr -s "\t"
}
select_mirror() {
@@ -37,7 +27,7 @@
--menu \
"" \
0 70 10 \
- `mirror_list $1`
+ $(mirror_list $1)
}
mirror_menu() {
@@ -56,13 +46,13 @@
--cancel-label "Exit" \
--item-help \
--menu "" 0 0 0 \
- "GNOME" "" "$N_HELP" \
- "GNU" "" "$G_HELP" \
- "KDE" "" "$K_HELP" \
- "KERNEL" "" "$L_HELP" \
- "SFORGE" "" "$SF_HELP" \
- "LRESORT" "" "$LR_HELP" \
- "XFREE86" "" "$X_HELP"`
+ "GNOME" "" "$N_HELP" \
+ "GNU" "" "$G_HELP" \
+ "KDE" "" "$K_HELP" \
+ "KERNEL" "" "$L_HELP" \
+ "SFORGE" "" "$SF_HELP" \
+ "LRESORT" "" "$LR_HELP" \
+ "XFREE86" "" "$X_HELP"`
do
case $COMMAND in
@@ -75,9 +65,9 @@
LRESORT) MIRROR=" LRESORT_URL" ;;
esac
- if MIRROR_URL=`select_mirror $COMMAND`; then
+ if MIRROR_URL=$(select_mirror $COMMAND); then
if [ "$MIRROR_URL" == "Custom" ]; then
- MIRROR_URL=`$DIALOG --inputbox "Please enter the URL." 0 0`
+ MIRROR_URL=$($DIALOG --inputbox "Please enter the URL." 0 0)
fi
if [ -n "$MIRROR_URL" ] ; then
More information about the Lunar-commits
mailing list