[Apt-offline-devel] [SCM] Offline APT Package Manager branch, apt-offline-qt, updated. v0.9.9-110-gdeef88f
Ritesh Raj Sarraf
rrs at researchut.com
Sat Aug 21 15:40:14 UTC 2010
The following commit has been merged in the apt-offline-qt branch:
commit a788c68a4140965cde6ff2ebcdb7c5225c996f66
Merge: aa8b0ad648587776ffeb10a792ca2007a96e2a7a b98c4cf83faeb9b0d4091dd4c3f2ef50369155a3
Author: Ritesh Raj Sarraf <rrs at researchut.com>
Date: Sat Aug 21 20:40:38 2010 +0530
Merge branch 'master' into apt-offline-qt
* master:
check for dir arg during install
add .gitignore
Conflicts:
.gitignore
diff --combined apt_offline_core/AptOfflineCoreLib.py
index 1df5d9a,0bb38a4..2949c4e
--- a/apt_offline_core/AptOfflineCoreLib.py
+++ b/apt_offline_core/AptOfflineCoreLib.py
@@@ -50,8 -50,13 +50,8 @@@ except ImportError
import AptOfflineMagicLib
-guiBool = True
-try:
- from qt import *
- from AptOfflineGUI import pyptofflineguiForm
-except ImportError:
- guiBool = False
-
+guiBool = False
+
#INFO: Check if python-apt is installed
PythonApt = True
try:
@@@ -95,11 -100,6 +95,11 @@@ LINE_OVERWRITE_SMALL = " " * 1
LINE_OVERWRITE_MID = " " * 30
LINE_OVERWRITE_FULL = " " * 60
+Bool_Verbose = False
+#Bool_TestWindows = True
+
+log = AptOfflineLib.Log( Bool_Verbose, lock=True )
+
class FetchBugReports( AptOfflineLib.Archiver ):
def __init__( self, apt_bug_file_format, IgnoredBugTypes, ArchiveFile=None, lock=False ):
@@@ -206,9 -206,17 +206,9 @@@ def find_first_match(cache_dir=None, fi
return os.path.join(path, file)
return False
-
-class DownloadFromWeb(AptOfflineLib.ProgressBar):
- '''Class for DownloadFromWeb
- This class also inherits progressbar functionalities from
- parent class, ProgressBar'''
-
- def __init__(self, width, total_items):
- '''width = Progress Bar width'''
- AptOfflineLib.ProgressBar.__init__(self, width=width, total_items=total_items)
-
- def download_from_web(self, url, file, download_dir):
+
+class GenericDownloadFunction():
+ def download_from_web(self, url, file, download_dir):
'''url = url to fetch
file = file to save to
donwload_dir = download path'''
@@@ -279,17 -287,6 +279,17 @@@
errfunc(e.code, e.reason, file)
except socket.timeout:
errfunc(10054, "Socket timeout.\n", url)
+
+class DownloadFromWeb(AptOfflineLib.ProgressBar, GenericDownloadFunction):
+ '''Class for DownloadFromWeb
+ This class also inherits progressbar functionalities from
+ parent class, ProgressBar'''
+
+ def __init__(self, width, total_items):
+ '''width = Progress Bar width'''
+ AptOfflineLib.ProgressBar.__init__(self, width=width, total_items=total_items)
+
+
def stripper(item):
@@@ -1180,6 -1177,9 +1180,9 @@@ def installer( args )
filename = eachfile
FullFileName = os.path.abspath(os.path.join(InstallDirPath, eachfile) )
+ if os.path.isdir(FullFileName):
+ log.verbose("Skipping!! %s is a directory\n" % (FullFileName))
+ continue
#INFO: Take care of Src Pkgs
found = False
for item in SrcPkgDict.keys():
--
Offline APT Package Manager
More information about the apt-offline-devel
mailing list