Skip to content

Commit 86f705f

Browse files
humitosagjohnson
authored andcommitted
Add GLOBAL_PIP_CACHE setting (#3299)
Avoid downloading over and over again the pip packages when you are developing over a slow internet connection.
1 parent 8de1770 commit 86f705f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

readthedocs/projects/models.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,8 @@ def checkout_path(self, version=LATEST):
441441
@property
442442
def pip_cache_path(self):
443443
"""Path to pip cache"""
444+
if getattr(settings, 'GLOBAL_PIP_CACHE', False):
445+
return settings.GLOBAL_PIP_CACHE
444446
return os.path.join(self.doc_path, '.cache', 'pip')
445447

446448
#

0 commit comments

Comments
 (0)