Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1717)

Unified Diff: git_cache.py

Issue 216013002: Suppress spurious warning about overriding cache dir. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: git_cache.py
diff --git a/git_cache.py b/git_cache.py
index 9ef4873874e34557211344623e4b41fadfe7d310..b47b163975d3288a90dafddfdb9128374b23eb5f 100755
--- a/git_cache.py
+++ b/git_cache.py
@@ -290,7 +290,10 @@ class OptionParser(optparse.OptionParser):
global_cache_dir = subprocess.check_output(
[GIT_EXECUTABLE, 'config', '--global', 'cache.cachepath']).strip()
if options.cache_dir:
- logging.warn('Overriding globally-configured cache directory.')
+ if global_cache_dir and (
+ os.path.abspath(options.cache_dir) !=
+ os.path.abspath(global_cache_dir)):
+ logging.warn('Overriding globally-configured cache directory.')
else:
options.cache_dir = global_cache_dir
except subprocess.CalledProcessError:
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698