mirror of https://github.com/Calamitous/iris.git
Tweak and alphabetize command-line option completions and documentation
This commit is contained in:
parent
4da59d6230
commit
94ccc65647
96
README.md
96
README.md
|
@ -385,25 +385,50 @@ This displays helpful reminders of the commands that Iris supports.
|
||||||
|
|
||||||
There are a few options you can pass in from the command-line:
|
There are a few options you can pass in from the command-line:
|
||||||
|
|
||||||
* [--version, -v](#--version-v)
|
* [--debug](#--debug)
|
||||||
* [--stats, -s](#--stats-s)
|
|
||||||
* [--interactive, -i](#--interactive-i)
|
|
||||||
* [--mark-all-read](#--mark-all-read)
|
|
||||||
* [--dump, -d](#--dump-d)
|
* [--dump, -d](#--dump-d)
|
||||||
* [--help, -h](#--help-h)
|
* [--help, -h](#--help-h)
|
||||||
* [--debug](#--debug)
|
* [--interactive, -i](#--interactive-i)
|
||||||
|
* [--mark-all-read](#--mark-all-read)
|
||||||
|
* [--stats, -s](#--stats-s)
|
||||||
|
* [--test-file, -s](#--test-file)
|
||||||
|
* [--version, -v](#--version-v)
|
||||||
|
|
||||||
### --version/-v
|
### --debug
|
||||||
|
|
||||||
This displays the current version of Iris and exits.
|
This option turns on debug mode. Warnings and errors will be output as the program is used.
|
||||||
|
|
||||||
```bash
|
Having these messages constantly appear can be distracting or annoying during regular Iris usage, but are useful when tracking down issues.
|
||||||
iris --version
|
|
||||||
```
|
|
||||||
|
|
||||||
```bash
|
This option works in both interactive and non-interactive mode.
|
||||||
Iris 1.1.1
|
|
||||||
```
|
---
|
||||||
|
|
||||||
|
### --dump/-d
|
||||||
|
|
||||||
|
This reads the entire message corpus and outputs it as a stream of JSON data, suitable for piping into a backup file, `jq` parser, or similar.
|
||||||
|
|
||||||
|
This command does not enter Iris' interactive mode.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### --help/-h
|
||||||
|
|
||||||
|
This command displays a complete list of options that Iris recognizes.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### --interactive/-i
|
||||||
|
|
||||||
|
This command enters Iris' interactive mode, the default mode with which users can compose and read topics and replies.
|
||||||
|
|
||||||
|
This is the mode that Iris enters if no options are passed on the command-line.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### --mark-all-read
|
||||||
|
|
||||||
|
This command simply marks every message as read in Iris. It's a quick way to get to "Irisbox Zero".
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
@ -426,39 +451,6 @@ Iris 1.1.1
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
### --interactive/-i
|
|
||||||
|
|
||||||
This command enters Iris' interactive mode, the default mode with which users can compose and read topics and replies.
|
|
||||||
|
|
||||||
This is the mode that Iris enters if no options are passed on the command-line.
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
|
|
||||||
### --mark-all-read
|
|
||||||
|
|
||||||
This command simply marks every message as read in Iris. It's a quick way to get to "Irisbox Zero".
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
### --dump/-d
|
|
||||||
|
|
||||||
This reads the entire message corpus and outputs it as a stream of JSON data, suitable for piping into a backup file, `jq` parser, or similar.
|
|
||||||
|
|
||||||
This command does not enter Iris' interactive mode.
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
### --debug
|
|
||||||
|
|
||||||
This option turns on debug mode. Warnings and errors will be output as the program is used.
|
|
||||||
|
|
||||||
Having these messages constantly appear can be distracting or annoying during regular Iris usage, but are useful when tracking down issues.
|
|
||||||
|
|
||||||
This option works in both interactive and non-interactive mode.
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
### --test-file/-f
|
### --test-file/-f
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
@ -471,9 +463,17 @@ This option works in both interactive and non-interactive mode.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
### --help/-h
|
### --version/-v
|
||||||
|
|
||||||
This command displays a complete list of options that Iris recognizes.
|
This displays the current version of Iris and exits.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
iris --version
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash
|
||||||
|
Iris 1.1.1
|
||||||
|
```
|
||||||
|
|
||||||
## Text Features/Markup
|
## Text Features/Markup
|
||||||
|
|
||||||
|
|
|
@ -17,21 +17,21 @@ _iris_module() {
|
||||||
|
|
||||||
case $cur in
|
case $cur in
|
||||||
--*)
|
--*)
|
||||||
OPTS="--help
|
OPTS="--debug
|
||||||
--version
|
|
||||||
--stats
|
|
||||||
--interactive
|
|
||||||
--dump
|
--dump
|
||||||
|
--help
|
||||||
|
--interactive
|
||||||
|
--stats
|
||||||
--test-file
|
--test-file
|
||||||
--debug"
|
--version"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
OPTS="-h
|
OPTS="-d
|
||||||
-v
|
-f
|
||||||
-s
|
-h
|
||||||
-i
|
-i
|
||||||
-d
|
-s
|
||||||
-f"
|
-v"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
|
@ -8,19 +8,20 @@ function _iris {
|
||||||
typeset -A opt_args
|
typeset -A opt_args
|
||||||
|
|
||||||
_arguments -C \
|
_arguments -C \
|
||||||
"-h[Show help information]" \
|
"--debug[Print warnings and debug informtation during use]" \
|
||||||
"--help[Show help information]" \
|
|
||||||
"-v[Display the current version of Iris]" \
|
|
||||||
"--version[Display the current version of Iris]" \
|
|
||||||
"-s[Display Iris version and message stats]" \
|
|
||||||
"--stats[Display Iris version and message stats]" \
|
|
||||||
"-i[Enter interactive mode (default)]" \
|
|
||||||
"--interactive[Enter interactive mode (default)]" \
|
|
||||||
"-d[Dump entire message corpus out]" \
|
"-d[Dump entire message corpus out]" \
|
||||||
"--dump[Dump entire message corpus out]" \
|
"--dump[Dump entire message corpus out]" \
|
||||||
|
"-h[Show help information]" \
|
||||||
|
"--help[Show help information]" \
|
||||||
|
"-i[Enter interactive mode (default)]" \
|
||||||
|
"--interactive[Enter interactive mode (default)]" \
|
||||||
|
"--mark-all-read[Mark every message in Iris as \"read\".]"
|
||||||
|
"-s[Display Iris version and message stats]" \
|
||||||
|
"--stats[Display Iris version and message stats]" \
|
||||||
"-f[Use the specified test file for messages]:f:->f" \
|
"-f[Use the specified test file for messages]:f:->f" \
|
||||||
"--test-file[Use the specified test file for messages]:f:->f" \
|
"--test-file[Use the specified test file for messages]:f:->f" \
|
||||||
"--debug[Print warnings and debug informtation during use]"
|
"-v[Display the current version of Iris]" \
|
||||||
|
"--version[Display the current version of Iris]" \
|
||||||
|
|
||||||
if [ "$state" = "f" ]; then
|
if [ "$state" = "f" ]; then
|
||||||
_files
|
_files
|
||||||
|
|
Loading…
Reference in New Issue