mirror of
https://github.com/dockur/macos.git
synced 2026-03-11 08:34:24 +00:00
feat: Remove leading and trailing spaces from VERSION (#294)
This commit is contained in:
parent
9fb20e6ef5
commit
27a66f4748
1 changed files with 7 additions and 0 deletions
|
|
@ -211,6 +211,13 @@ generateSerial() {
|
|||
return 0
|
||||
}
|
||||
|
||||
if [[ "${VERSION}" == \"*\" || "${VERSION}" == \'*\' ]]; then
|
||||
VERSION="${VERSION:1:-1}"
|
||||
fi
|
||||
|
||||
VERSION=`expr "$VERSION" : "^\ *\(.*[^ ]\)\ *$"`
|
||||
[ -z "$VERSION" ] && VERSION="13"
|
||||
|
||||
if [ ! -f "$BASE_IMG" ] || [ ! -s "$BASE_IMG" ]; then
|
||||
! download "$VERSION" && exit 34
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in a new issue