Squashed 'vendor/git.knownelement.com/ExternalVendorCode/bash3boilerplate/' content from commit 2e878ec
git-subtree-dir: vendor/git.knownelement.com/ExternalVendorCode/bash3boilerplate git-subtree-split: 2e878ec30f0572ad80f34743b6136536cf7c202f
This commit is contained in:
32
test/scenario/main-usage-defaults/run.sh
Executable file
32
test/scenario/main-usage-defaults/run.sh
Executable file
@@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env bash
|
||||
set -o pipefail
|
||||
set -o errexit
|
||||
set -o nounset
|
||||
# set -o xtrace
|
||||
|
||||
__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
__root="$(cd "$(dirname "$(dirname "$(dirname "${__dir}")")")" && pwd)"
|
||||
|
||||
read -r -d '' __usage <<-'EOF' || true # exits non-zero when EOF encountered
|
||||
-1 --one Do one thing. Default="ONE"
|
||||
More description.
|
||||
-2 --two Do two things.
|
||||
More description. Default="TWO"
|
||||
-3 --three [arg] Do three things. Default="'THREE'"
|
||||
More description.
|
||||
-4 --four [arg] Do four things.
|
||||
More description. Default='"FOUR"'
|
||||
-5 --five [arg] Do five things. Default="FIVE"
|
||||
More description. Default='OOOPS'
|
||||
-6 --six [arg] Do six things.
|
||||
More description.
|
||||
EOF
|
||||
|
||||
export __usage
|
||||
|
||||
echo "ACCPTST:STDIO_REPLACE_DATETIMES"
|
||||
|
||||
# shellcheck source=main.sh
|
||||
source "${__root}/main.sh"
|
||||
|
||||
for argument in ${!arg_*}; do info "${argument}: ${!argument}"; done
|
Reference in New Issue
Block a user