6 releases (3 breaking)

0.3.0 Sep 25, 2024
0.2.0 Jul 3, 2024
0.1.2 Jun 7, 2024
0.1.1 Apr 12, 2024
0.0.0 Feb 15, 2024

#120 in Windows APIs

Download history 1888/week @ 2024-07-18 3477/week @ 2024-07-25 3941/week @ 2024-08-01 6203/week @ 2024-08-08 55859/week @ 2024-08-15 179664/week @ 2024-08-22 181267/week @ 2024-08-29 218379/week @ 2024-09-05 222329/week @ 2024-09-12 241732/week @ 2024-09-19 280961/week @ 2024-09-26 299189/week @ 2024-10-03 291354/week @ 2024-10-10 317173/week @ 2024-10-17 309011/week @ 2024-10-24 407967/week @ 2024-10-31

1,385,076 downloads per month
Used in 4,349 crates (9 directly)

MIT/Apache

99KB
2.5K SLoC

Windows registry

The windows-registry crate provides simple, safe, and efficient access to the Windows registry.

Start by adding the following to your Cargo.toml file:

[dependencies.windows-registry]
version = "0.3"

Read and write registry keys and values as needed:

use windows_registry::*;

fn main() -> Result<()> {
    let key = CURRENT_USER.create("software\\windows-rs")?;

    key.set_u32("number", 123)?;
    key.set_string("name", "Rust")?;

    println!("{}", key.get_u32("number")?);
    println!("{}", key.get_string("name")?);

    Ok(())
}

Dependencies

~0–4MB