cttt-parser

Crates.iocttt-parser
lib.rscttt-parser
version0.1.2
sourcesrc
created_at2023-08-10 05:47:37.705867
updated_at2023-08-10 07:26:13.05892
descriptionParser for github.com/change-this-then-that
homepage
repository
max_upload_size
id940628
size36,797
Justin Poehnelt (jpoehnelt)

documentation

README

cttt-parser

Crates.io Docs.rs Test Audit

A parser for the Change This Then That.

Examples

Basic usage:

let s = "
// @cttt.name(foo)
let x = 1;
// @cttt.change(bar)

// @cttt.name(bar)
let y = 2;
// @cttt.change(foo)
";

println!("{:#?}", cttt_parser::parse(s));

Strict usage:

let s = "
// @cttt.name(foo)
let x = 1;
// @cttt.change(bar)

// @cttt.name(bar)
let y = 2;
// @cttt.change(foo)
";

println!(
  "{:#?}",
  cttt_parser::parse_strict(s, vec!["name".to_string(), "change".to_string()])
);
Commit count: 0

cargo fmt