Registry / utility / temp-dir

temp-dir

JSON →
library0.2.0rscratesunverified

Simple temporary directory with cleanup.

# Cargo.toml [dependencies] temp-dir = "0.2.0"
INSTALL
IMPORT
SIG · TEMP-DIR
T
temp-dir
utilityrustv0.2.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

TempDir
use temp_dir::TempDir;

Creates a temporary directory that is automatically cleaned up.

use temp_dir::TempDir; let dir = TempDir::new().unwrap(); let path = dir.path().join("test.txt"); std::fs::write(&path, b"hello").unwrap(); println!("Created temp file at {:?}", path); // Directory is automatically deleted when `dir` goes out of scope.
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.2.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
temp-dir — cargo add temp-dir · libregistry