Fix regets.
This commit is contained in:
parent
cc9bb72726
commit
930f0f2667
@ -1,3 +1,7 @@
|
||||
* Mon Oct 29 2007 Jesse Keating <jkeating@redhat.com>
|
||||
- Check to see if the cached package is same size or larger and if so remove
|
||||
it. Otherwise regets will freak out.
|
||||
|
||||
* Tue Oct 23 2007 Jesse Keating <jkeating@redhat.com>
|
||||
- Add java-development to the group set.
|
||||
|
||||
|
2
pungi
2
pungi
@ -115,7 +115,7 @@ if __name__ == '__main__':
|
||||
today = time.strftime('%Y%m%d', time.localtime())
|
||||
|
||||
def get_arguments(config):
|
||||
parser = OptionParser(version="%prog 1.1.8")
|
||||
parser = OptionParser(version="%prog 1.1.9")
|
||||
|
||||
def set_config(option, opt_str, value, parser, config):
|
||||
config.set('default', option.dest, value)
|
||||
|
@ -1,7 +1,7 @@
|
||||
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
||||
|
||||
Name: pungi
|
||||
Version: 1.1.8
|
||||
Version: 1.1.9
|
||||
Release: 1%{?dist}
|
||||
Summary: Distribution compose tool
|
||||
|
||||
@ -51,6 +51,9 @@ rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Oct 29 2007 Jesse Keating <jkeating@redhat.com> - 1.1.9-1
|
||||
- Remove oversized cached packages (fixes reget problem)
|
||||
|
||||
* Sat Oct 27 2007 Jesse Keating <jkeating@redhat.com> - 1.1.8-1
|
||||
- Add eclipse group.
|
||||
|
||||
|
@ -330,12 +330,19 @@ class Gather(pypungi.PungiBase):
|
||||
local = os.path.join(self.config.get('default', 'cachedir'), basename)
|
||||
target = os.path.join(pkgdir, basename)
|
||||
|
||||
cursize = os.stat(local)[6]
|
||||
totsize = long(po.size)
|
||||
|
||||
if os.path.exists(local) and self.verifyCachePkg(po, local):
|
||||
self.logger.debug("%s already exists and appears to be complete" % local)
|
||||
if os.path.exists(target):
|
||||
os.remove(target) # avoid traceback after interrupted download
|
||||
self._link(local, target)
|
||||
continue
|
||||
else:
|
||||
# Check to see if the file on disk is bigger, and if so, remove it
|
||||
if cursize >= totsize:
|
||||
os.unlink(local)
|
||||
|
||||
# Disable cache otherwise things won't download
|
||||
repo.cache = 0
|
||||
|
Loading…
Reference in New Issue
Block a user