8 releases

✓ Uses Rust 2018 edition

0.2.0 Dec 14, 2019
0.1.1 Dec 14, 2019
0.0.4 Nov 28, 2019
Download history 58/week @ 2020-02-28 16/week @ 2020-03-06 8/week @ 2020-03-13 40/week @ 2020-03-20 144/week @ 2020-03-27 121/week @ 2020-04-03 120/week @ 2020-04-10 8/week @ 2020-04-17 8/week @ 2020-04-24 18/week @ 2020-05-01 8/week @ 2020-05-08 97/week @ 2020-05-15 97/week @ 2020-05-22 17/week @ 2020-05-29 26/week @ 2020-06-05 25/week @ 2020-06-12

189 downloads per month

Apache-2.0

27KB
616 lines

Yogurt Yaml

This package allows the user to extract yaml from yogurt files, where yogurt files are bassically all files containing a Identifier[.*]-like syntax. This package only extracts ID[.*], REF[.*], ADD[.*] or END[.*]. There will be a cli version with more options and functionality: yogurt-cli.

Usage

There is a lib and a executable, which can be used to extract yaml content specified by e.g.: ID[.*], REF[.*], ADD[.*] or END[.*].

Pipe file.md

# Title

Text in a file.

ID[NAME, attribute: value]

## Next Title

More text

REF[NAME, attribute: value, other_attribute: other_value]

Into curt-extract

 cat file.md | curt-extract -b "ID REF" > result.yaml

Returns result.yaml

- {ID: NAME, attribute: value}
- {REF: NAME, attribute: value, other_attribute: other_value}

CLI Examples

Simple Example

It is possible to extract yaml from any file.

cat file | curt-extract -b ID

More sophisticated Example

Other commandline tools can be used to extend the functionality.

cat **/*.adoc | curt-extract -b ID | yaml json write - | less

Dependencies

~265KB