How do I

Open the portal, name the script, list the options, preview, and download the zip. The zip parses the flags, checks the values, writes the help, and includes an installer.

Open the portal

Open the portal. There is no account.

Name the script

Pick a name. Pick bash or zsh. One script is one shell.

Add the options

Add each option in the order you want it in the help. A long name is required. A short name is one letter, and it is optional. Write one line of help. Pick a type and its checks.

Drag a row, or use Move up and Move down, to change that order.

Types

An option is a string, an integer, or a switch. A string or an integer takes a value. An integer can be signed. A switch is present or absent. It has no value.

Checks

A string or an integer can be required. A string has one format check: email, URL, letters and numbers, UUID, host, port, or date. It can also have a minimum length, a maximum length, a list of choices, or a path that must be a file or a directory. File and directory look at the path on the machine that runs the script. An integer can have a lower bound and an upper bound.

Preview

Preview shows the entry script and the framework. It does not download a zip.

Download

Create Script downloads the zip. The zip is the program. Unzip it, then run:

chmod 755 installer.sh
./installer.sh

The installer and the uninstaller are bash, even when the script is zsh. Files land in $HOME/.lickety-script. Put $HOME/.lickety-script/bin on PATH. Set LICKETY_SCRIPT_HOME to $HOME/.lickety-script.

Run

Run the script by the name you chose. --help and --verbose are already there. Your code starts only after the checks pass.

A value is NAME_ARG. NAME_OPTION_CHOSEN is 1 when the option was present and 0 when it was not.

Exits

ExitMeaning
0The checks passed. Your code runs.
1A value was missing or invalid.
3An unknown flag, or a positional argument.

A notify script

A notify script with a required email option sets these names before your code runs:

EMAIL_OPTION_CHOSEN=0
EMAIL_ARG=''

Its help includes this line:

      -e, --email who (required, string)

The shared functions ship in the zip. Names start with a dot. .die, .need, .trim, .tmpdir, and .sha256 are included. The readme in the zip lists the rest. The manual covers the checks, the files in the zip, and every shared function.