summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2006-03-06 18:58:21 +0000
committerMichael Vogt <michael.vogt@ubuntu.com>2006-03-06 18:58:21 +0000
commit251a9c10f4c848df5d1daaef63a16e4ce6d5dc0b (patch)
treed238879e4790d5fddd4bdce3bf905af9cb23e3f3
parenteb14999105a40543ee791bfa1c22b5dcf3d6fe37 (diff)
downloadpython-apt-251a9c10f4c848df5d1daaef63a16e4ce6d5dc0b.tar.gz
* added purge option
-rw-r--r--apt/package.py9
-rw-r--r--debian/changelog4
2 files changed, 9 insertions, 4 deletions
diff --git a/apt/package.py b/apt/package.py
index 4fceb904..66bfd72b 100644
--- a/apt/package.py
+++ b/apt/package.py
@@ -274,10 +274,13 @@ class Package(object):
self._pcache.cachePreChange()
self._depcache.MarkKeep(self._pkg)
self._pcache.cachePostChange()
- def markDelete(self, autoFix=True):
- """ mark a package for delete. Run the resolver if autoFix is set """
+ def markDelete(self, autoFix=True, purge=False):
+ """ mark a package for delete. Run the resolver if autoFix is set.
+ Mark the package as purge (remove with configuration) if 'purge'
+ is set.
+ """
self._pcache.cachePreChange()
- self._depcache.MarkDelete(self._pkg)
+ self._depcache.MarkDelete(self._pkg, purge)
# try to fix broken stuffsta
if autoFix and self._depcache.BrokenCount > 0:
Fix = apt_pkg.GetPkgProblemResolver(self._depcache)
diff --git a/debian/changelog b/debian/changelog
index 23f586d9..f9a26c49 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -9,7 +9,9 @@ python-apt (0.6.16.2) unstable; urgency=low
- fix various pychecker warnings
* apt/cache.py:
- return useful values on Cache.update()
- * apt/cache.py, apt/package.py: fix various pychecker warnings
+ * apt/package.py:
+ - fix various pychecker warnings
+ - added setDelete(purge) option
--