From c6188975d2da6c1696c4433f6fce8ae4c9a6ac38 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Wed, 12 Apr 2023 08:15:20 -0300 Subject: bin/: Make help string more consistent across several executables --- bin/80 | 1 + bin/assert-arg | 1 + bin/aux | 2 ++ bin/backup | 1 + bin/bins | 1 + bin/boop | 2 ++ bin/clamp | 7 +++++++ bin/color | 10 ++++++++-- bin/copy | 14 +++++++++++--- bin/dice | 2 ++ bin/e | 15 ++++++++++----- bin/email | 1 + bin/forever | 5 ++++- bin/gc | 1 + bin/gen-password | 1 + bin/git-cleanup | 1 + bin/grun | 11 ++++++++--- bin/htmlesc | 1 + bin/httpno | 1 + bin/ifnew | 7 +++++++ bin/lc | 1 + bin/lines | 1 + bin/max | 7 +++++++ bin/menu | 1 + bin/min | 6 ++++++ bin/mkdtemp | 1 + bin/mkstemp | 1 + bin/msg | 6 ++++++ bin/n-times | 6 +++++- bin/nato | 1 + bin/ootb | 10 +++++----- bin/open | 11 +++++++++++ bin/player | 1 + bin/playlist | 1 + bin/pre | 4 ++++ bin/print | 14 ++++++++++++++ bin/prompt | 3 ++- bin/qr | 1 + bin/reconfigure | 1 + bin/rfc | 5 ++++- bin/serve | 1 + bin/shesc | 1 + bin/slugify | 1 + bin/stopwatch | 1 + bin/tmp | 3 +++ bin/tmpname | 1 + bin/tuivid | 1 + bin/uc | 1 + bin/untill | 5 ++++- bin/update | 1 + bin/uuid | 1 + bin/vcs | 16 ++++++++++++++++ bin/volume | 1 + bin/without-env | 17 +++++++++++++++-- bin/wms | 1 + bin/xmpp | 1 + bin/yt | 2 ++ bin/z | 4 +++- 58 files changed, 200 insertions(+), 26 deletions(-) (limited to 'bin') diff --git a/bin/80 b/bin/80 index 298efff..9ab6fb4 100755 --- a/bin/80 +++ b/bin/80 @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/assert-arg b/bin/assert-arg index 3c8990a..477a571 100755 --- a/bin/assert-arg +++ b/bin/assert-arg @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/aux b/bin/aux index e092b1f..4c652ca 100755 --- a/bin/aux +++ b/bin/aux @@ -17,6 +17,8 @@ help() { Options: -h, --help show this message + FILE specific path to be written + Hydrate software project with auxiliary files. If FILE is given, restrict effect to those paths. diff --git a/bin/backup b/bin/backup index 4e95ed8..2c23a98 100755 --- a/bin/backup +++ b/bin/backup @@ -43,6 +43,7 @@ help() { $ backup + Create backup with comment, and verbose mode active: $ backup -qC 'The backup has a comment' my-backup diff --git a/bin/bins b/bin/bins index 494f4f0..76909fd 100755 --- a/bin/bins +++ b/bin/bins @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -F force remove the cache file -h, --help show this message diff --git a/bin/boop b/bin/boop index 23d1ed4..546c95c 100755 --- a/bin/boop +++ b/bin/boop @@ -11,6 +11,7 @@ usage() { help() { cat <<-'EOF' + Options: -m MESSAGE text message of the desktop notification (default: COMMAND) @@ -26,6 +27,7 @@ help() { $ boop echo 123 + Fail with the underlying 127 return code with the message "ERROR": diff --git a/bin/clamp b/bin/clamp index fab6967..a2c8bee 100755 --- a/bin/clamp +++ b/bin/clamp @@ -12,9 +12,14 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message + NUMBER the number to be clamped + MIN lower bound + MAX upper bound + Clamp the NUMBER between MIN and MAX. @@ -26,11 +31,13 @@ help() { $ clamp 5 3 9 5 + When a number is below MIN it gets clamped: $ clamp 1 3 9 3 + When a number is above MAX it gets clamped: $ clamp 15 3 9 diff --git a/bin/color b/bin/color index 240da87..a416079 100755 --- a/bin/color +++ b/bin/color @@ -13,19 +13,24 @@ usage() { help() { cat <<-'EOF' + Options: - -c COLOR + -c COLOR color name -h, --help show this message + TEXT literal string to be coloured + - Print the given text with a color. + Print TEXT using COLOR. The available colors are: EOF + list_colors | sed 's/^/ /' cat <<-'EOF' + Examples: Print "banana" in yellow: @@ -33,6 +38,7 @@ help() { $ color -c yellow 'banana' banana + Print "grass" in green, with a newline: $ color -c green 'grass\n' diff --git a/bin/copy b/bin/copy index 64e1e32..d7ffd61 100755 --- a/bin/copy +++ b/bin/copy @@ -4,7 +4,7 @@ set -eu usage() { cat <<-'EOF' Usage: - copy [-n] < STDIN + copy [-n] copy -h EOF } @@ -12,17 +12,25 @@ usage() { help() { cat <<-'EOF' + Options: -n remove newlines -h, --help show this message + + Copy data from STDIN to the X11 clipboard. + + Examples: Copy numbers to clipboard: - seq 10 | copy + + $ seq 10 | copy + Copy string without newline: - echo 'with automatic newline' | copy -n + + $ echo 'with automatic newline' | copy -n EOF } diff --git a/bin/dice b/bin/dice index 4a145d0..e0b3b6e 100755 --- a/bin/dice +++ b/bin/dice @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message @@ -29,6 +30,7 @@ help() { $ dice 3 + Roll a D20: $ dice 20 diff --git a/bin/e b/bin/e index b2778e1..3f8e93d 100755 --- a/bin/e +++ b/bin/e @@ -12,11 +12,18 @@ usage() { help() { cat <<-'EOF' + Options: - -h, --help + -h, --help show this message + + FILE path to the file + + Flexibly run a text editor, either directly or in a pipe. + + The editor used is either $VISUAL or $EDITOR, with a fallback to + vi in case any of those variables aren't defined. - Flexibly run a text editor, either directly on in a pipe. Examples: @@ -24,12 +31,10 @@ help() { $ e file.txt + Manipulate the content of a pipe midway: $ seq 10 | e | grep 5 - - The editor used is either $VISUAL or $EDITOR, with a fallback to - vi in case any of those variables aren't defined. EOF } diff --git a/bin/email b/bin/email index e6b055c..7c6eca4 100755 --- a/bin/email +++ b/bin/email @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -s SUBJECT the email subject (default: "CLI email: No subject") -f FROM the addr to send from (default: "eu@euandre.org") diff --git a/bin/forever b/bin/forever index a865fa3..aad2a29 100755 --- a/bin/forever +++ b/bin/forever @@ -4,7 +4,7 @@ set -eu usage() { cat <<-'EOF' Usage: - forever [-q] -- COMMAND... + forever [-q] COMMAND... forever -h EOF } @@ -12,10 +12,13 @@ usage() { help() { cat <<-'EOF' + Options: -q quiet mode, don't print exit code messages -h, --help show this message + COMMAND shell command to be wrapped + Run COMMAND forever. diff --git a/bin/gc b/bin/gc index 94dc417..f51e60a 100755 --- a/bin/gc +++ b/bin/gc @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/gen-password b/bin/gen-password index 327858f..07ed9ab 100755 --- a/bin/gen-password +++ b/bin/gen-password @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/git-cleanup b/bin/git-cleanup index 4196cff..f09fe9f 100755 --- a/bin/git-cleanup +++ b/bin/git-cleanup @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/grun b/bin/grun index e9cfebe..5bae057 100755 --- a/bin/grun +++ b/bin/grun @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -r RECIPIENT the recipient to encrypt to. Can be provided multiple times for multiple recipients. @@ -23,18 +24,22 @@ help() { FILENAME The GPG-encrypted file to be processed. If it doesn't exist yet, it will be created. + + Edit the encripted FILENAME in a pipeline, using COMMAND to + modify the content. If COMMAND emits a non-zero return code, + the file is left unmodified. + + Examples: Edit "secrets.txt.gpg" using `vipe` and the default recipient: $ grun secrets.txt.gpg -- vipe + Delete lines containing "TODO" in todos.gpg for specific keys: $ grun -r ABC123DEF321 todos.gpg -- sed '/TODO/d' - - If COMMAND emits a non-zero return code, the file is left - unmodified. EOF } diff --git a/bin/htmlesc b/bin/htmlesc index 0e4c75a..436ed54 100755 --- a/bin/htmlesc +++ b/bin/htmlesc @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -e escape the string (the default action) -d unescape (de-escape?) the string diff --git a/bin/httpno b/bin/httpno index 50cc48c..a03d5cb 100755 --- a/bin/httpno +++ b/bin/httpno @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/ifnew b/bin/ifnew index 8d5c434..2a72922 100755 --- a/bin/ifnew +++ b/bin/ifnew @@ -39,6 +39,13 @@ help() { $ echo bbb | ifnew new-file $ stat --print='%y' new-file # timestamp 2 + + + Only change file when content changes in a Makefile: + + i18.cfg: ALWAYS + gen-cfg | ifnew $@ + po4a $@ EOF } diff --git a/bin/lc b/bin/lc index 111b91b..993e7bc 100755 --- a/bin/lc +++ b/bin/lc @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/lines b/bin/lines index 6cda6f0..7823a22 100755 --- a/bin/lines +++ b/bin/lines @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/max b/bin/max index ae38983..d63f82d 100755 --- a/bin/max +++ b/bin/max @@ -12,9 +12,13 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message + NUMBER the list of numbers to get the max from + + Get the maximum number from the given values. @@ -25,16 +29,19 @@ help() { $ min 5 3 9 9 4 9 + Get the maximum number when negative numbers are given $ max -- -3 -5 -3 + Get the maximum number given a single number $ max 8 8 + The maximum default number: $ max diff --git a/bin/menu b/bin/menu index 648fc94..68fd507 100755 --- a/bin/menu +++ b/bin/menu @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/min b/bin/min index 715f4d1..fcb685d 100755 --- a/bin/min +++ b/bin/min @@ -12,9 +12,12 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message + NUMBER the list of numbers to get the min from + Get the minimun number from the given values. @@ -26,16 +29,19 @@ help() { $ min 5 3 9 9 4 3 + Get the minimum number when negative numbers are given $ min -- -3 -5 -5 + Get the minimum number given a single number $ min 8 8 + The minimum default number: $ min diff --git a/bin/mkdtemp b/bin/mkdtemp index 3729dd4..9c5f8c8 100755 --- a/bin/mkdtemp +++ b/bin/mkdtemp @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/mkstemp b/bin/mkstemp index 4097e59..ded9837 100755 --- a/bin/mkstemp +++ b/bin/mkstemp @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/msg b/bin/msg index 84d25a7..6bf875f 100755 --- a/bin/msg +++ b/bin/msg @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -X send MESSAGE using the `xmpp` command -s play $XDG_DATA_HOME/msg/{good,bad}.ogg sound @@ -25,12 +26,17 @@ help() { MESSAGE the text to be sent by the relevant channel + + Send MESSAGE via all the selected channels. + + Examples: Ring a terminal bell and play a sound, representing an error: $ msg -1sb + Send an email and an XMPP message: $ msg -mX 'The message goes here' diff --git a/bin/n-times b/bin/n-times index c8d10d8..660b734 100755 --- a/bin/n-times +++ b/bin/n-times @@ -4,7 +4,7 @@ set -eu usage() { cat <<-'EOF' Usage: - n-times COUNT -- COMMAND... + n-times COUNT COMMAND... n-times -h EOF } @@ -12,12 +12,16 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message COUNT the number of times for COMMAND to be executed + Run COMMAND, COUNT times. + + Examples: Print 123 5 times: diff --git a/bin/nato b/bin/nato index fec460d..6a049e1 100755 --- a/bin/nato +++ b/bin/nato @@ -17,6 +17,7 @@ sub usage($fh) { sub help($fh) { print $fh <<~'EOF'; + Options: -h, --help show this message diff --git a/bin/ootb b/bin/ootb index 2b98454..959a210 100755 --- a/bin/ootb +++ b/bin/ootb @@ -39,11 +39,11 @@ help() { 'build-1/' directory with: build-1/ - Makefile -> /absolute/path/to/Makefile - README.md -> /absolute/path/to/README.md + Makefile -> ../Makefile + README.md -> ../README.md src/ - file1.ext -> /absolute/path/to/file1.ext - file2.ext -> /absolute/path/to/file2.ext + file1.ext -> ../../src/file1.ext + file2.ext -> ../../src/file2.ext With that one can `cd build-1/` and run builds there, without the build artifacts littering the source tree. Also, one could @@ -99,5 +99,5 @@ mkdir -p "$BUILD_DIRECTORY" while read -r f; do mkdir -p "$BUILD_DIRECTORY"/"$(dirname "$f")" - ln -fs "$PWD"/"$f" "$BUILD_DIRECTORY"/"$f" + ln -rfs "$PWD"/"$f" "$BUILD_DIRECTORY"/"$f" done diff --git a/bin/open b/bin/open index a57e13e..4dc56db 100755 --- a/bin/open +++ b/bin/open @@ -12,19 +12,30 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message + FILE path to file to be opened + + + Wrapper for xdg-open(1). + + Examples: Open an HTML file on the current $BROWSER: + $ open index.html + Open multiple PDF files (with zathura): + $ open *.pdf EOF } + for flag in "$@"; do case "$flag" in --) diff --git a/bin/player b/bin/player index f247806..cc71c9d 100755 --- a/bin/player +++ b/bin/player @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/playlist b/bin/playlist index 8b9271f..ebe0902 100755 --- a/bin/playlist +++ b/bin/playlist @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/pre b/bin/pre index f588310..fdbd3d9 100755 --- a/bin/pre +++ b/bin/pre @@ -12,10 +12,14 @@ usage() { help() { cat <<-'EOF' + Options: -c COLOR ANSI color to be used on the prefix text -h, --help show this message + PREFIX the string to insert at the beginning + + Prefix STDIN with PREFIX. diff --git a/bin/print b/bin/print index 4911ecd..f26831d 100755 --- a/bin/print +++ b/bin/print @@ -12,24 +12,38 @@ usage() { help() { cat <<-'EOF' + Options: -d print duplex/double-sided -q QUALITY choose the print quality, either: low, medium (default) or high. -h, --help show this message + FILE path to file to be printed + + + Print FILE using CUPS using lp(1). + + Examples: Print the given PostScript file with default quality: + $ print f1.ps + Print multiple PDF files with high quality: + $ print -dq high *.pdf + Print the file from STDIN, double-sided: + $ print -d < f2.ps + Print multiple source code files: + $ print src/*.{c,h} EOF } diff --git a/bin/prompt b/bin/prompt index 382588d..326908a 100755 --- a/bin/prompt +++ b/bin/prompt @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message @@ -24,7 +25,7 @@ help() { Examples: - Conditionally run download command + Conditionally run download command: if prompt 'Download files?'; then run_download; diff --git a/bin/qr b/bin/qr index c0462e1..26c7e22 100755 --- a/bin/qr +++ b/bin/qr @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -s PIXEL_SIZE size of the pixel (default 10) -h, --help show this help message diff --git a/bin/reconfigure b/bin/reconfigure index d166819..ca38cb1 100755 --- a/bin/reconfigure +++ b/bin/reconfigure @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -U run update(1) before acting -h, --help show this message diff --git a/bin/rfc b/bin/rfc index 0860f45..fd36ac7 100755 --- a/bin/rfc +++ b/bin/rfc @@ -23,12 +23,16 @@ usage() { help() { cat <<-'EOF' + Options: -w show the path to the RFC file instead of displaying its contents -u update the local RFC database -h, --help show this message + RFC_NUMBER the RFC id number + + Lookup the given RFC in $XDG_DATA_HOME/doc/rfc/ (defaults to ~/.local/share), and feed it into the $PAGER, akin to doing: @@ -42,7 +46,6 @@ help() { Examples: - Show RFC 1234 in $PAGER: $ rfc 1234 diff --git a/bin/serve b/bin/serve index 82a0663..25e8fe7 100755 --- a/bin/serve +++ b/bin/serve @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -d DIRECTORY the directory to serve (default: ".") -p PORT the port to listen on (default: find one) diff --git a/bin/shesc b/bin/shesc index 0c5e25a..5849b64 100755 --- a/bin/shesc +++ b/bin/shesc @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/slugify b/bin/slugify index 955a849..834e4bc 100755 --- a/bin/slugify +++ b/bin/slugify @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/stopwatch b/bin/stopwatch index 3d5cd07..14182d2 100755 --- a/bin/stopwatch +++ b/bin/stopwatch @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/tmp b/bin/tmp index 5e64b66..df7f097 100755 --- a/bin/tmp +++ b/bin/tmp @@ -13,10 +13,13 @@ usage() { help() { cat <<-'EOF' + Options: -d delete the remote "tmp/" folder -h, --help show this message + FILE path to files to be copied + Copies a file to the public server. diff --git a/bin/tmpname b/bin/tmpname index 89d7e4d..ea3f0aa 100755 --- a/bin/tmpname +++ b/bin/tmpname @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/tuivid b/bin/tuivid index 54bddcf..5bfaf4b 100755 --- a/bin/tuivid +++ b/bin/tuivid @@ -13,6 +13,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/uc b/bin/uc index e8bd9fb..bf577ba 100755 --- a/bin/uc +++ b/bin/uc @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/untill b/bin/untill index 738b5bb..9980c81 100755 --- a/bin/untill +++ b/bin/untill @@ -4,7 +4,7 @@ set -eu usage() { cat <<-'EOF' Usage: - until [-m MAX] [-n SECONDS] -- COMMAND... + until [-m MAX] [-n SECONDS] COMMAND... until -h EOF } @@ -12,12 +12,15 @@ usage() { help() { cat <<-'EOF' + Options: -n SECONDS the amount of seconds to sleep between attempts (default: 5) -m MAX the maximum number of attempts (default: unlimited) -h, --help show this message + COMMAND the shell command to be executed + Runs COMMAND until it eventually succeeds, trying atmost MAX times. Sleep SECONDS between attempts. diff --git a/bin/update b/bin/update index e59aeae..a185612 100755 --- a/bin/update +++ b/bin/update @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/uuid b/bin/uuid index 34b685f..f4c7809 100755 --- a/bin/uuid +++ b/bin/uuid @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/vcs b/bin/vcs index 95a597a..6913348 100755 --- a/bin/vcs +++ b/bin/vcs @@ -191,6 +191,22 @@ help() { - status - gc - ls + + + Wrapper command for normalizing options of differenct version + control software. + + + Examples: + + Say the type of repo in "project/": + + $ vcs -C project/ -t + + + Fetch updates for VCS in current directory: + + $ vcs fetch EOF } diff --git a/bin/volume b/bin/volume index 9056760..cd2a44d 100755 --- a/bin/volume +++ b/bin/volume @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/without-env b/bin/without-env index 57c2d2e..4e7ed15 100755 --- a/bin/without-env +++ b/bin/without-env @@ -4,7 +4,7 @@ set -eu usage() { cat <<-'EOF' Usage: - without-env ENVVAR PATH -- COMMAND... + without-env ENVVAR PATH COMMAND... without-env -h EOF } @@ -12,17 +12,30 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message + ENVVAR the name of the environment variable to be modifed + PATH section to be excluded from ENVVAR + COMMAND command to be wrapped + + + Execute COMMAND, but changing the variable ENVVAR by excluding + PATH from it. + + Examples: Execute "command -V" filtering ~/bin, to get where "w3m" is in $PATH, other than ~/bin: + $ without-env PATH ~/bin -- command -v w3m + Compile foo.c, excluding ~/.local/include from $C_INCLUDE_PATH: + $ without-env C_INCLUDE_PATH ~/.local/include -- cc -co foo.o foo.c EOF } @@ -60,7 +73,7 @@ shift $((OPTIND - 1)) eval "$(assert-arg -- "${1:-}" 'ENVVAR')" eval "$(assert-arg -- "${2:-}" 'PATH')" -eval "export $1=\"\$(echo \"\$$1\" | sed \"s|\$2:||g\")\"" +eval "export $1=\"\$(echo \"\$$1\" | sed \"s|\$2||g\")\"" shift # drop $1 shift # drop $2 if [ "${1:-}" = '--' ]; then diff --git a/bin/wms b/bin/wms index a9a5784..4eb0eae 100755 --- a/bin/wms +++ b/bin/wms @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -h, --help show this message diff --git a/bin/xmpp b/bin/xmpp index 50c55ba..3c5dbc3 100755 --- a/bin/xmpp +++ b/bin/xmpp @@ -12,6 +12,7 @@ Usage: xmpp -h""" HELP = """ + Options: -d run in DEBUG mode -m MESSAGE the text of the message to be sent diff --git a/bin/yt b/bin/yt index aa39fd1..83b32cb 100755 --- a/bin/yt +++ b/bin/yt @@ -12,6 +12,7 @@ usage() { help() { cat <<-'EOF' + Options: -n PLAYLIST_COUNT the number of videos to grab from a playlist (default: 15) @@ -23,6 +24,7 @@ help() { FILE a file with 'https://...' addresses, one per line + Download videos and store them locally. diff --git a/bin/z b/bin/z index 5c25550..ad3ca9b 100755 --- a/bin/z +++ b/bin/z @@ -13,7 +13,7 @@ use List::Util qw(any); sub usage($fh) { print $fh <<~'EOF'; Usage: - z COMMANDS... + z COMMAND... z -h EOF } @@ -25,6 +25,8 @@ sub help($fh) { Options: -h, --help show this message + COMMAND shell command to be wrapped + Wrapper that uncompresses file arguments to commands. This enables having commands that operate on plain files to not -- cgit v1.2.3