#run-command #programs #running #anywhere #ease #robust #variables

xscript

A library for writing robust shell-script-like programs and running commands anywhere with ease

5 unstable releases

0.3.0 Dec 23, 2023
0.2.0 Jul 23, 2023
0.1.2 Jul 9, 2023
0.1.1 Jul 9, 2023
0.1.0 Jul 9, 2023

#299 in Unix APIs

Download history 38/week @ 2024-03-14 8/week @ 2024-03-21 26/week @ 2024-03-28 31/week @ 2024-04-04 7/week @ 2024-04-11 16/week @ 2024-04-18 102/week @ 2024-04-25 387/week @ 2024-05-02 357/week @ 2024-05-09 193/week @ 2024-05-16 313/week @ 2024-05-23 349/week @ 2024-05-30 510/week @ 2024-06-06 269/week @ 2024-06-13 193/week @ 2024-06-20 313/week @ 2024-06-27

1,351 downloads per month

MIT/Apache

48KB
1.5K SLoC

XScript

A library for writing robust shell-script-like programs and running commands anywhere with ease.

XScript Crate Docs License: MIT/Apache

use xscript::{read_str, run, vars, Run, LocalEnv};

let mut env = LocalEnv::current_dir()?.with_vars(vars! {
    RUSTDOCFLAGS = "--cfg docsrs --cfg xscript_unstable",
    RUSTFLAGS = "--cfg xscript_unstable",
});

let project_root = read_str!(env, ["git", "rev-parse", "--show-toplevel"])?;
env.change_dir(project_root)?;

let cargo_args = ["+nightly"];
let doc_args = ["--lib", "--all-features"];
run!(env, ["cargo", ...cargo_args, "doc", ...doc_args])?;

Checkout the documentation for details.

⚖️ Licensing

This project is licensed under either MIT or Apache 2.0 at your opinion. Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache 2.0 license, shall be dual licensed as above, without any additional terms or conditions.


Made with ❤️ for OSS by Silitics.

Dependencies

~0–14MB
~136K SLoC