diff options
author | William Langford <wlangfor@gmail.com> | 2019-02-20 20:58:25 -0500 |
---|---|---|
committer | Nico Williams <nico@cryptonector.com> | 2019-02-26 11:10:38 -0600 |
commit | 53a3f47076b930ff01d65da340300a0adfb822aa (patch) | |
tree | 06577b1a220b8aeb0b8ea6881797b471f7ffa480 /docs | |
parent | 175dbc4e25098e50d5173578d6b36df7abb5c549 (diff) |
Remove ruby dependency from mantests
Diffstat (limited to 'docs')
-rwxr-xr-x | docs/build_mantests.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/docs/build_mantests.py b/docs/build_mantests.py new file mode 100755 index 00000000..40f0dccf --- /dev/null +++ b/docs/build_mantests.py @@ -0,0 +1,13 @@ +#!/usr/bin/env python3 +import yaml + +with open("content/manual/manual.yml") as f: + manual = yaml.load(f) + for section in manual.get('sections', []): + for entry in section.get('entries', []): + for example in entry.get('examples', []): + print(example.get('program', '').replace('\n', ' ')) + print(example.get('input', '')) + for s in example.get('output', []): + print(s) + print('') |