diff options
author | Pavan Jadhaw <pavanjadhaw96@gmail.com> | 2017-12-31 22:11:51 +0530 |
---|---|---|
committer | Pavan Jadhaw <pavanjadhaw96@gmail.com> | 2017-12-31 22:11:51 +0530 |
commit | cd33700ba21e37fcc5ff5e8e812db5c0bf4f3b95 (patch) | |
tree | c6339b142446b76ac039c65f7f57dbd7a33f562f | |
parent | 13bdde37c0dfcbdd564db5366a9418ce4f07af08 (diff) |
Just small change
-rwxr-xr-x | betterlockscreen | 76 |
1 files changed, 41 insertions, 35 deletions
diff --git a/betterlockscreen b/betterlockscreen index f699b94..30cab6e 100755 --- a/betterlockscreen +++ b/betterlockscreen @@ -70,41 +70,10 @@ rec_get_random() { rec_get_random "$dir" } +usage() { -# Options -case "$1" in - "") - if [ ! -f $l_dim ]; then - - echo "Important : Update the image cache, Ex. betterlockscreen -u path/to/image.jpg" - echo - echo " Image cache must be updated to initially configure or update wallpaper used" - echo - echo "See also : For other set of options and help use help command." - echo "Ex. betterlockscreen -h or betterlockscreen --help" - - echo - echo "See : https://github.com/pavanjadhaw/betterlockscreen for addition info..." - exit 1 - else - echo - echo "Seems you havent provided any argument, see below for usage info" - echo - echo "See also : For other set of options and help use help command." - - echo "Ex. betterlockscreen -h or betterlockscreen --help" - - echo - echo "See : https://github.com/pavanjadhaw/betterlockscreen for addition info..." - echo - exit 1 - fi - ;; - - -h | --help) - - echo "Important : Update the image cache, Ex: betterlockscreen -g path/to/image.jpg" - echo " Image cache must be updated to initially configure or update wallpaper used" + echo "Important : Update the image cache, Ex: betterlockscreen -g path/to/image.jpg" + echo " Image cache must be updated to initially configure or update wallpaper used" echo echo echo "See : https://github.com/pavanjadhaw/betterlockscreen for additional info..." @@ -160,7 +129,44 @@ case "$1" in echo " used to set blur intensity. Default to 1." echo " Ex: betterlockscreen -u path/to/image.png -b 3" echo " Ex: betterlockscreen -u path/to/image.png --blur 0.5" - echo + echo + +} + +# Options +case "$1" in + "") + if [ ! -f $l_dim ]; then + + echo "Important : Update the image cache, Ex. betterlockscreen -u path/to/image.jpg" + echo + echo " Image cache must be updated to initially configure or update wallpaper used" + echo + echo "See also : For other set of options and help use help command." + echo "Ex. betterlockscreen -h or betterlockscreen --help" + + echo + echo "See : https://github.com/pavanjadhaw/betterlockscreen for addition info..." + exit 1 + else + echo + echo "Seems you havent provided any argument, see below for usage info" + echo + echo "See also : For other set of options and help use help command." + + echo "Ex. betterlockscreen -h or betterlockscreen --help" + + echo + echo "See : https://github.com/pavanjadhaw/betterlockscreen for addition info..." + echo + exit 1 + fi + ;; + + -h | --help) + + usage + ;; -l | --lock) |