mirror of
https://github.com/Snigdha-OS/snigdhaos-system-config.git
synced 2025-09-21 03:55:00 +02:00
⚡️ perf(usage): usage() function is more informative, with clearer examples and a description of options
This commit is contained in:
@@ -8,9 +8,15 @@ set -euo pipefail # Enable strict error handling
|
||||
LAUNCH_TERMINAL_SHELL=bash
|
||||
|
||||
usage() {
|
||||
echo "Usage: ${0##*/} [cmd]"
|
||||
echo ' -s [shell] Change shell to [shell]'
|
||||
echo ' -h This help'
|
||||
echo "Usage: ${0##*/} [options] [command]"
|
||||
echo
|
||||
echo "Options:"
|
||||
echo " -s [shell] Change shell to [shell] (default: bash)"
|
||||
echo " -h Show this help message"
|
||||
echo
|
||||
echo "Example:"
|
||||
echo " ${0##*/} -s zsh 'echo Hello, World!'"
|
||||
echo " ${0##*/} -h"
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user