<documentation>
--cacheonly
If you're using this as a user yum will not use the tempcache for
the user but will only use the system cache in the system cachedir.
</documentation>
setCacheDir() sets up the user tempcache when UID != 0.
Thus, we should avoid calling it with --cacheonly.
---
cli.py | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/cli.py b/cli.py
index afa7447..d9d6a4b 100755
--- a/cli.py
+++ b/cli.py
@@ -1916,9 +1916,7 @@ class YumOptionParser(OptionParser):
self.base.conf.assumeno = 1
# Treat users like root as much as possible:
- if not self.base.setCacheDir():
- self.base.conf.cache = 1
- if opts.cacheonly:
+ if opts.cacheonly or not self.base.setCacheDir():
self.base.conf.cache = 1
if opts.obsoletes:
--
1.7.4.4
_______________________________________________
Yum-devel mailing list
[email protected]
http://lists.baseurl.org/mailman/listinfo/yum-devel