diff options
author | mail_redacted_for_web | 2014-08-10 03:33:16 +0200 |
---|---|---|
committer | mail_redacted_for_web | 2014-08-10 03:33:16 +0200 |
commit | e58068694698ff4f426ec07396a829f1f24ff6b5 (patch) | |
tree | cc668c24184e94d72846505f129e5e16b014c7b6 /bin/mp3dirlist | |
parent | 9a7bdd871431148cee77aef5d7286cdaca2a06be (diff) | |
download | mp3dir2html-e58068694698ff4f426ec07396a829f1f24ff6b5.tar.bz2 |
+help, +option -d for directory to be scanned
Diffstat (limited to 'bin/mp3dirlist')
-rwxr-xr-x | bin/mp3dirlist | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/bin/mp3dirlist b/bin/mp3dirlist index 81eeb66..4966614 100755 --- a/bin/mp3dirlist +++ b/bin/mp3dirlist @@ -10,21 +10,25 @@ DIRLISTEX='^Susperia|^B.*hse.*nkelz' # CORE SCRIPT FROM HERE. DON'T FIDDLE IF YOU DON'T KNOW WHAT YOU'RE DOING. function m3l_help { - echo "Usage: $(basename $0) [options] [DIRECTORY...]" - exit 0 + echo "Usage: $(basename $0) [options]";echo + echo "Options:" + echo -e "\t-h\t\tPrint this help text and exit" + echo -e "\t-d DIRECTORY\tSpecify a directory to be scanned" } while getopts "ht:r:p:v" params; do case $params in "h") m3l_help + exit 0 + ;; + "d") + SDIR="$OPTARG" ;; esac done -if [ "$1" == "" ]; then +if [ "$SDIR" == "" ]; then SDIR="*" -else - SDIR="$1 $2 $3 $4 $5 $6 $7 $8" fi function m3l_rm_verb { |