[Lunar-commits] <lunar> Connect() no longer needed

Stefan Wold ratler at lunar-linux.org
Wed Jan 9 21:18:30 CET 2013


commit 3a7b7797b3c0d7aecdae266015ec534ea713600f
Author: Stefan Wold <ratler at lunar-linux.org>
Date: Wed, 09 Jan 2013 12:18:30 -0800
URL: https://github.com/lunar-linux/lunar/commit/3a7b7797b3c0d7aecdae266015ec534ea713600f

Connect() no longer needed

Due to a change in the interface naming scheme as of the latest
release of systemd there's no longer a safe way to detect interface
names thus rendering this code deprecated.

Automatic dialup code has been removed as of this commit and we no
longer check if an active interface exists, lget/lin will just
timeout if there is no internet connectivity.
---
  libs/connect.lunar  | +0/-79    
  libs/download.lunar | +0/-1     
  prog/lvu            | +0/-1     
  3 files changed, 81 deletions(-)

--- a/libs/connect.lunar
+++ /dev/null
@@ -1,79 +0,0 @@
-#!/bin/bash
-############################################################
-#                                                          #
-# download.lunar - get sources from the net                #
-#                                                          #
-############################################################
-# leach is part of the sorcery spell management utility    #
-# Copyright 2001 by Kyle Sallee                            #
-############################################################
-#                                                          #
-# this WAS the leach script of a source based Linux distro,#
-# calls Sorcerer GNU/Linux, or SGL. SGL is no longer       #
-# available with GPL license. Since this script was taken  #
-# before licensing scheme change, no legal problems I      #
-# guess.                                                   #
-#                                                          #
-# the code is re-written for Lunar. The previous Copyright #
-# notices are kept; just in case some code is left :=)     #
-# Kagan Kongar <kongar at tsrsb.org.tr>, 20020519             #
-#                                                          #
-# This secondly was lget mostly, and has been moved into   #
-# a separate lunar functions file handling all the generic #
-# downloading functionality for lunar                      #
-#                                                          #
-############################################################
-#                                                          #
-# Parts Copyrighted  Jason Johnston  2002 under GPLv2      #
-#                                                          #
-# Parts Copyrighted  Kagan Kongar  2002 under GPLv2        #
-#                                                          #
-# Parts Copyrighted  Auke Kok  2002 under GPLv2            #
-#                                                          #
-############################################################
-
-
-connect()  {
-  local TIMEOUT
-  debug_msg "connect ($@)"
-
-  if ! ip link | egrep -q '^[0-9]*: (eth|wlan|ppp|ath|tun|ra|usb|br)[0-9]+[^>]*[<,]UP[,>]'
-  then
-    pon
-
-    # Timeout in deciseconds to wait for Interface to come up.
-    TIMEOUT=30
-
-    until ip link | egrep -q '^[0-9]*: (eth|wlan|ppp|ath|tun|ra|usb|br)[0-9]+[^>]*[<,]UP[,>]' || [ $TIMEOUT == 0  ]
-    do
-      sleep  10
-      (( TIMEOUT-- ))
-    done
-    disconnect
-
-  fi
-
-}
-
-
-disconnect()  {
-  debug_msg "disconnect ($@)"
-  if    ps  -C disconnect  >  /dev/null
-  then  return
-  fi
-
-  rm  -f           $TMPDIR/disconnect
-  cat  <<  EOF  >  $TMPDIR/disconnect
-#!/bin/sh
-
-while  ps  -A  |  grep  -q  "lget";  do  sleep  120;  done
-poff
-rm  -f  $TMPDIR/disconnect
-EOF
-
-chmod  a+x  $TMPDIR/disconnect
-            $TMPDIR/disconnect  &
-
-}
-
-
--- a/libs/download.lunar
+++ b/libs/download.lunar
@@ -37,7 +37,6 @@ download_url() {
 	local RETVAL
 	debug_msg "download_url($@)"
 	verbose_msg "trying to download \"${2}\" from \"${1}\""
-	connect &&
 	plugin_call SOURCE_DOWNLOAD $1 $2 $3
 	return $?
 }
--- a/prog/lvu
+++ b/prog/lvu
@@ -812,7 +812,6 @@ show_urls() { (
     echo $URL$2
     return 1
   }
-  connect() { return 0 ; }
 
   LRESORT_URL=
   FRESORT_URL=




More information about the Lunar-commits mailing list