Display / set / update the dtool cache directory.
973751
def cache(cache_directory_path):
    """"""
    if not cache_directory_path:
        click.secho(dtool_config.utils.get_cache(
            CONFIG_PATH,
        ))
    else:
        click.secho(dtool_config.utils.set_cache(
            CONFIG_PATH,
            cache_directory_path
        ))
1317504
def enable_caching(self, file_path=None):
        

        if not file_path:
            file_path = tempfile.mktemp(prefix="pylast_tmp_")

        self.cache_backend = _ShelfCacheBackend(file_path)
943989
function() {
      ss.http.cached.loadStatic();
      ss.http.cached.loadAssets();
      ss.bundler.updateCachedOndemandAssets();

      ss.bundler.forEach(function(bundler) {
        bundler.updateCachedDevAssets();
      });
    }
1235087
def chdir(self, directory, browsing_history=False,
              refresh_explorer=True, refresh_console=True):
        """"""
        if directory:
            directory = osp.abspath(to_text_string(directory))

        # Working directory history management
        if browsing_history:
            directory = self.history[self.histindex]
        elif directory in self.history:
            self.histindex = self.history.index(directory)
        else:
            if self.histindex is None:
                self.history = []
            else:
                self.history = self.history[:self.histindex+1]
            self.history.append(directory)
            self.histindex = len(self.history)-1
        
        # Changing working directory
        try:
            os.chdir(directory)
            if refresh_explorer:
                self.set_explorer_cwd.emit(directory)
            if refresh_console:
                self.set_current_console_wd.emit(directory)
            self.refresh_findinfiles.emit()
        except OSError:
            self.history.pop(self.histindex)
        self.refresh_plugin()
214462
def set_current_client_working_directory(self, directory):
        """"""
        shellwidget = self.get_current_shellwidget()
        if shellwidget is not None:
            shellwidget.set_cwd(directory)
1330269
def _cache(cpath, arg):
        '''
        
        '''
        if not os.path.isdir(cpath): os.makedirs(cpath)
        for (k,v) in six.iteritems(arg):
            save(os.path.join(cpath, k + '.pp'), v, create_directories=True, overwrite=True)
        return True
221223
def use_software_cache(sw_dir=None, reload_deps=False):
    
    sw_dir = get_sw_dir(sw_dir)
    if os.path.exists(sw_dir):
        sys.path.insert(1, sw_dir)

        if reload_deps:
            reload_dependencies()
1290003
def create_cache_directories(self):
        """"""
        if not os.path.isdir(self.package_cache_dir):
            if not os.path.isdir(self.stacker_cache_dir):
                os.mkdir(self.stacker_cache_dir)
            os.mkdir(self.package_cache_dir)
814732
def user_cache_dir(self):
        """"""
        directory = appdirs.user_cache_dir(self.appname, self.appauthor,
                              version=self.version)
        if self.create:
            self._ensure_directory_exists(directory)
        return directory
532856
def update_default_output_dir(self):
        """"""
        if self.scenario_directory_radio.isChecked():
            self.output_directory.setText(self.source_directory.text())
1280840
def set_dir(self, dir_):
        """"""

        self.__lock_set_dir(dir_)
        self.__lock_auto_load()
        self.__lock_update_table()
        self.__update_info()
        self.__update_window_title()
1137938
protected function setCachePath()
    {
        $filename = basename($this->pathFile);

        $this->pathCache = $this->cacheDir . '/' . $filename;
    }
32655
def cache_files(db, aid: int, anime_files: AnimeFiles) -> None:
    """"""
    with db:
        cache_status(db, aid)
        db.cursor().execute(
            """UPDATE cache_anime
            SET anime_files=?
            WHERE aid=?""",
            (anime_files.to_json(), aid))
365603
def _refresh(self):
        
        log.debug('refreshing directory cache')
        self._users.update(list(self._user_gen()))
        self._channels.update(list(self._channel_gen()))
196974
def _fill_cache(self, namespace):
        """"""

        modules = self._findPluginModules(namespace)

        self._cache = list(modules)
1160527
def user_cache_dir():
    
    """
    if WINDOWS:
        path = os.path.join(os.environ.get('LOCALAPPDATA') or os.environ.get('APPDATA'),
                            'glances', 'cache')
    elif MACOS:
        path = os.path.expanduser('~/Library/Caches/glances')
    else:
        path = os.path.join(os.environ.get('XDG_CACHE_HOME') or os.path.expanduser('~/.cache'),
                            'glances')

    return path
1066877
private static void addCacheInfoUpdate(CacheStatus cacheStatus) {
    long cacheSize = cacheStatus.size;
    synchronized (baseDirSize) {
      Long dirSize = baseDirSize.get(cacheStatus.getBaseDir());
      if( dirSize == null ) {
        dirSize = Long.valueOf(cacheSize);
      } else {
        dirSize += cacheSize;
      }
      baseDirSize.put(cacheStatus.getBaseDir(), dirSize);
    }
    synchronized (baseDirNumberSubDir) {
      Integer dirSubDir = baseDirNumberSubDir.get(cacheStatus.getBaseDir());
      if( dirSubDir == null ) {
        dirSubDir = 1;
      } else {
        dirSubDir += 1;
      }
      baseDirNumberSubDir.put(cacheStatus.getBaseDir(), dirSubDir);
    }
  }