mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2025-06-30 11:02:51 -05:00
[youtube] Move cache into its own module
This commit is contained in:
@ -1076,12 +1076,6 @@ def intlist_to_bytes(xs):
|
||||
return bytes(xs)
|
||||
|
||||
|
||||
def get_cachedir(params={}):
|
||||
cache_root = os.environ.get('XDG_CACHE_HOME',
|
||||
os.path.expanduser('~/.cache'))
|
||||
return params.get('cachedir', os.path.join(cache_root, 'youtube-dl'))
|
||||
|
||||
|
||||
# Cross-platform file locking
|
||||
if sys.platform == 'win32':
|
||||
import ctypes.wintypes
|
||||
|
Reference in New Issue
Block a user