#shim #serialization #parser #scoop #path #parser-serializer

scoop-shim

A simple parser and serializer for Scoop shims

2 releases

0.1.1 Oct 27, 2024
0.1.0 Oct 25, 2024

#1122 in Encoding

Download history 255/week @ 2024-10-23 16/week @ 2024-10-30 1/week @ 2024-11-06

272 downloads per month

Apache-2.0

13KB
323 lines

Scoop Shims

Usage

use scoop_shim::Shim;

// Serialize a shim
let shim = Shim::new(
    std::path::PathBuf::from("sfsu.exe"),
    vec!["search".to_string()],
);

shim.to_string(); // "path = \"sfsu.exe\"\r\nargs = search"

// Deserialize a shim
let shim = scoop_shim::from_str("path = \"sfsu.exe\"\r\nargs = search").unwrap();

assert_eq!(shim.path(), std::path::PathBuf::from("sfsu.exe"));
assert_eq!(shim.args(), ["search".to_string()]);

Made with 💗 by Juliette Cordor

Dependencies

~290–760KB
~18K SLoC