## Requirements
[Nix](https://nixos.org/download.html) with [flakes enabled](https://github.com/mschwaig/howto-install-nix-with-flake-support) must be available.
## Usage
Run all demos in order using
```console
$ ./demo-full.sh
```
or run one particular demo using `./<xx-demo-name>/demo.sh`.
Available options:
```console
$ ./demo-full.sh -h
./demo-full.sh: run all 'demo.sh' scripts using libdemo
-l|--lint: run linter on shell files
-a|--auto: run in automatic mode
-h|--help|-?: Show usage
```
Available environment variables:
* `LIBDEMO_USE_COLOUR`: enable (1, default) or disable (0) the use of colour in libdemo. Colours may still appear in output from other packages.
* `LIBDEMO_USE_UNICODE`: enable (1, default) or disable (0) the use of unicode in libdemo. Unicode may still appear in output from other packages.
* `LIBDEMO_INTERACTIVE`: enable (1, default) or disable (0) interactive mode. In non-interactive (automatic) mode, there is no waiting for input and some commands (prefixed with `i`) are skipped.
## libdemo
An attempt at making live, but prepared, presentations in bash.
Demo files `demo.sh` are bash files that source `libdemo.sh`, providing some convenience functions and abbreviated forms for them:
* `h` Print arguments as a header.
* `,` Print arguments as regular text.
* `x` Execute arguments, expect success.
* `f` Execute arguments, expect failure.
* `i` Execute arguments in interactive mode only. Ignore exit status.
* `c` Clear terminal.
Additional functions are provided that can be used in commands:
* `pygmentize`: Wrapper around [pygmentize](https://pygments.org/docs/cmdline/).