Creates a local temporary directory. The directory is removed when no longer needed. Failure to do
    so will be ignored.

    :return: Path to the temporary directory.
    :rtype: unicode
6467
def local_temp_dir():
    
    path = tempfile.mkdtemp()
    yield path
    shutil.rmtree(path, ignore_errors=True)
407174
def temp_file():
    
    fd, path = tempfile.mkstemp()
    os.close(fd)
    try:
        yield path
    finally:
        os.remove(path)
1221720
def temporary(self, path):
    """"""
    if path is None:
      raise ValueError('Can only temporarily establish a build root given a path.')
    prior = self._root_dir
    self._root_dir = path
    try:
      yield
    finally:
      self._root_dir = prior
226550
def tmppath(root=TEMPS_DIR, prefix=TEMPS_PREFIX, suffix=TEMPS_SUFFIX):
    '''
    
    '''
    return os.path.join(root, prefix + uuid.uuid4().hex + suffix)
1189872
def _open_tmpfile(self, **kwargs):
        
        self.tmpfile = get_tempfile(**kwargs)
        path = self.tmpfile.name
        return path
801096
def temp_path(file_name=None):
    

    if file_name is None:
        file_name = generate_timestamped_string("wtf_temp_file")

    return os.path.join(tempfile.gettempdir(), file_name)
1143851
def with_temp_dir(dir=nil)
      dir ||= Dir.mktmpdir(TEMP_PREFIX, @temp_root)
      dir = Pathname.new(dir)

      yield dir
    ensure
      FileUtils.rm_rf(dir.to_s)
    end
23018
def make_temp(suffix="", prefix="tmp", dir=None):
    
    temporary = tempfile.mkstemp(suffix=suffix, prefix=prefix, dir=dir)
    os.close(temporary[0])
    try:
        yield temporary[1]
    finally:
        os.remove(temporary[1])
1034456
def tmpdir(self):
        
        if self._tmpdir is None:
            self._tmpdir = mkdtemp(prefix="colin-", dir="/var/tmp")
        return self._tmpdir
419612
def mkdir(self, path):
        
        if not os.path.exists(path):
            os.makedirs(path)
902681
private Path createTemporaryStorage() {
        try {
            Path tempDir = Files.createTempDirectory("selenium");
            tempDir.toFile().deleteOnExit();

            log.info("Download storage location is: " + tempDir.toString());
            return tempDir;
        } catch (IOException e) {
            throw new CitrusRuntimeException("Could not create temporary storage", e);
        }
    }
1228390
def mktmp(self):
        
        try:
            if not os.path.isdir(self.location):
                os.makedirs(self.location)
        except:
            log.debug(self.location, exc_info=1)
        return self
689543
def empty_directory(path=None):
    
    install_dir = tempfile.mkdtemp(dir=path)
    try:
        yield install_dir
    finally:
        shutil.rmtree(install_dir)
37838
private void initTempDirectory(String tempDirRoot, boolean createTempSubDir) {

		tempDirPath = tempDirRoot;

		// In windows, pathnames with spaces are returned as %20
		if (tempDirPath.contains("%20"))
			tempDirPath = tempDirPath.replaceAll("%20", " ");

		this.textDirPath = tempDirPath + File.separator + TEMP_TEXT_SUBDIR;
		this.gzipDirPath = tempDirPath + File.separator + TEMP_GZIP_SUBDIR;
		this.cssClasspathDirPath = tempDirPath + File.separator + TEMP_CSS_CLASSPATH_SUBDIR;

		if (createTempSubDir) {
			try {
				createDir(tempDirPath);
				createDir(textDirPath);
				createDir(gzipDirPath);
				createDir(cssClasspathDirPath);
			} catch (IOException e) {
				throw new BundlingProcessException("Unexpected IOException creating temporary jawr directory", e);
			}
		}
	}
120100
def temporary_dir():
    
    d = tempfile.mkdtemp()
    try:
        with cd(d):
            yield d
    finally:
        if os.path.exists(d):
            shutil.rmtree(d)
417324
def create_directory(self, path):
        
        _complain_ifclosed(self.closed)
        return self.fs.create_directory(path)
1263652
def make_local_directories(self):
        
        for remote_path in self._get_parent_remote_paths():
            local_path = os.path.join(self.dest_directory, remote_path)
            self._assure_dir_exists(local_path)