4 releases (2 breaking)

0.2.0 Jul 31, 2021
0.1.0 Jul 3, 2021
0.0.1 Jul 3, 2021
0.0.0 Jan 1, 2020

#27 in #temporary

Download history 241/week @ 2024-11-17 128/week @ 2024-11-24 132/week @ 2024-12-01 251/week @ 2024-12-08 136/week @ 2024-12-15 75/week @ 2024-12-22 70/week @ 2024-12-29 86/week @ 2025-01-05 112/week @ 2025-01-12 203/week @ 2025-01-19 106/week @ 2025-01-26 127/week @ 2025-02-02 343/week @ 2025-02-09 156/week @ 2025-02-16 211/week @ 2025-02-23 328/week @ 2025-03-02

1,076 downloads per month
Used in 3 crates

CC0 license

7KB
140 lines

temptree: temporary trees of files


lib.rs:

Temptree creates temporary trees of files:

use temptree::temptree;

let tree = temptree! {
  foo: "a",
  bar: {
    baz: "b",
  },
};

let foo_contents = std::fs::read_to_string(tree.path().join("foo")).unwrap();
assert_eq!(foo_contents, "a");

let baz_contents = std::fs::read_to_string(tree.path().join("bar/baz")).unwrap();
assert_eq!(baz_contents, "b");

Dependencies

~2–11MB
~129K SLoC