add documentation and move up

This commit is contained in:
Faik Uygur
2009-03-05 06:53:22 +00:00
parent e33d761ab7
commit 2b5ae46b0c
+9 -6
View File
@@ -423,6 +423,15 @@ def get_takeback_plan(operation):
beinstalled, beremoved, configs = pisi.operations.history.plan_takeback(operation)
return beinstalled, beremoved
@locked
def delete_cache():
"""
Deletes cached packages, cached archives, build dirs
"""
pisi.util.clean_dir(ctx.config.cached_packages_dir())
pisi.util.clean_dir(ctx.config.archives_dir())
pisi.util.clean_dir(ctx.config.tmp_dir())
@locked
def snapshot():
"""
@@ -690,12 +699,6 @@ def __update_repo(repo, force=False):
else:
raise pisi.Error(_('No repository named %s found.') % repo)
@locked
def delete_cache():
pisi.util.clean_dir(ctx.config.cached_packages_dir())
pisi.util.clean_dir(ctx.config.archives_dir())
pisi.util.clean_dir(ctx.config.tmp_dir())
# FIXME: rebuild_db is only here for filesdb and it really is ugly. we should not need any rebuild.
@locked
def rebuild_db(files=False):