xpanda 0.1.0

Unix shell-like parameter expansion/variable substitution
Documentation
  • Coverage
  • 53.33%
    8 out of 15 items documented1 out of 11 items with examples
  • Size
  • Source code size: 119.94 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 3.26 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • Homepage
  • aesy/xpanda
    4 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • aesy

Xpanda Lib

API Reference

Usage

First create a new Xpanda struct using the builder:

use xpanda::Xpanda;

let xpanda = Xpanda::builder()
    // ...
    .build();

or use the default implementation:

let xpanda = Xpanda::default();

The default implementation sources values from environment variables and ignores unset variables (leaving an empty string).

The Xpanda struct implements a single method, expand, which will return a copy of the given string expanded according to the pattern rules. For example:

assert_eq!(xpanda.expand("${1:-default}"), Ok(String::from("default")));

The API Reference provides more details.

Installation

Add xpanda manually as a dependency in your Cargo.toml file or use the cargo add command:

cargo add xpanda

MSRV

The Minimum Supported Rust Version is currently 1.63.