Fixed cli argument... hopefully

This commit is contained in:
TuDatTr
2020-05-24 03:34:01 +02:00
parent 42a992a8c4
commit ed5168f596

View File

@@ -16,39 +16,39 @@ if [[ ${PIPESTATUS[0]} -ne 0 ]]; then
fi fi
eval set -- "$PARSED" eval set -- "$PARSED"
d="CHANGEME" # Device that shoud be partitioned e.g. "/dev/sda" device="CHANGEME" # Device that shoud be partitioned e.g. "/dev/sda"
t="CHANGEME" # Your timezone according to /usr/share/zoneinfo/ e.g. "/usr/share/zoneinfo/Europ/Berlin" timezone="CHANGEME" # Your timezone according to /usr/share/zoneinfo/ e.g. "/usr/share/zoneinfo/Europ/Berlin"
l="CHANGEME" # Your locale according to /etc/locale.gen e.g. "en_US.UTF-8 UTF-8" locale="CHANGEME" # Your locale according to /etc/locale.gen e.g. "en_US.UTF-8 UTF-8"
h="CHANGEME" # Name for your machine e.g. "ArchLinux" hostname="CHANGEME" # Name for your machine e.g. "ArchLinux"
u="CHANGEME" # Your username e.g. "foo" username="CHANGEME" # Your username e.g. "foo"
s="CHANGEME" # Name of the sudogrp sudogrp="CHANGEME" # Name of the sudogrp
CWD="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" CWD="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
while true; do while true; do
case "$1" in case "$1" in
-d|--device) -d|--device)
d="$2" device="$2"
shift 2 shift 2
;; ;;
-t|--timezone) -t|--timezone)
t="$2" timezone="$2"
shift 2 shift 2
;; ;;
-l|--locale) -l|--locale)
l="$2" locale="$2"
shift 2 shift 2
;; ;;
-h|--hostname) -h|--hostname)
h="$2" hostname="$2"
shift 2 shift 2
;; ;;
-u|--username) -u|--username)
u="$2" username="$2"
shift 2 shift 2
;; ;;
-s|--sudogrp) -s|--sudogrp)
s="$2" sudogrp="$2"
shift 2 shift 2
;; ;;
--help) --help)
@@ -67,6 +67,9 @@ Mandatory arguments:
" "
exit 0 exit 0
;; ;;
--)
shift
break
*) *)
echo "Programming error" echo "Programming error"
exit 3 exit 3