~nullevoid/args

A simple (KISS) Janet module for command line argument parsing

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~nullevoid/args
read/write
git@git.sr.ht:~nullevoid/args

You can also use your local clone with git send-email.

#Args

Args is a simple (44 sloc) pure Janet module for parsing command line flags.

Unlike argparse and it's ilk, this module only parses flags without arguments.

#install

Use JPM

sudo jpm install https://github.com/MorganPeterson/args.git

#examples

Run simple.janet script for an example of usage.

janet simple.janet -a -b -cd -x --help

The above should produce the following output:

A flag found
B flag found
C flag found
D flag found
don't recognize flag x
help message