# Stebalien/tempfile

Temporary file library for rust

Repository: https://github.com/Stebalien/tempfile
Canonical: https://ross.abutalabs.com/products/tempfile
Homepage: http://stebalien.com/projects/tempfile-rs
Language: Rust
License: Apache-2.0
License Family: permissive
Topics: library, rust, tempfile, filesystem-library, testing
Last push: 2026-08-14T02:32:57+00:00

## Health v2 (maintenance only)
Score: 76/100 (v2, computed 2026-09-03T02:39:23.370411+00:00)
- activity 97, release rhythm 35, longevity 100
- inputs: {"age_days": 4161, "days_push": 20, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1459, forks 152 (observed 2026-08-28T04:04:47.258240+00:00)

## What it is
A secure, cross-platform Rust library for creating and managing temporary files and directories. It supports anonymous temporary files, named temporary files, and securely opening multiple independent references to the same temporary file, with automatic cleanup on drop.

## Use cases
- create temporary files in rust
- securely manage temp files that auto-delete
- create named temporary files with a known path
- create temporary directories for test fixtures
- share a temporary file between producer and consumer safely
- cross-platform temp file handling including wasm/wasi

## When to choose
- you need secure, race-free temporary file creation in Rust
- you want automatic cleanup of temp files on drop
- you need cross-platform support including BSDs, Android, and WASI
- you need multiple independent handles to the same temp file

## When to avoid
- you need temporary files in a non-Rust project
- you need long-lived files that survive program aborts (NamedTempFile cleanup can be skipped if destructors don't run)
- your environment has pathological temp-directory cleaners and you rely on named paths

## Facets
- artifact type: library
- maturity: stable
- function: file-system, security, testing
- domain: developer-tools, files, cross-platform
- platform: rust, windows, bsd, wasm, cross-platform
- tags: tempfile, temporary-files, temporary-directories, filesystem, rust-crate, linux, macos, android, ios

## Member repositories
- Stebalien/tempfile (main) score 76

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:47.258240+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:35:26.983958+00:00, confidence not recorded.
  - readme: https://github.com/Stebalien/tempfile (fetched 2026-08-28T04:04:47.258240+00:00, sha 236f5375a7ee)
  - homepage: http://stebalien.com/projects/tempfile-rs (fetched 2026-08-29T11:44:16.524924+00:00, sha e64223eeac42)
  - registry_crates: https://crates.io/api/v1/crates/tempfile (fetched 2026-08-29T11:44:16.527496+00:00, sha 93a7d1a02857)
- Data as of 2026-08-30T08:39:29.467469+00:00.
