def clear_local_caches():
files = []
roots = set()
for window in sublime.windows():
# All views in a window share the same settings.
view = window.views()[0]
cwd = s_cwd(view)
local_root = File.local_root_for_cwd(cwd)
roots.add(local_root)
for root in roots:
log('Deleting local cache directory [{0}]...'.format(root))
if os.path.exists(root):
shutil.rmtree(root)
for file in files:
log("Refreshing open file [{0}]...".format(file.remote_path()))
download_file(file)
评论列表
文章目录