Avoid unnecessary subshell

This commit is contained in:
T. Joseph Carter 2018-09-06 13:01:29 -07:00
parent 34798abf11
commit 82016a398c

View File

@ -21,7 +21,7 @@ fi
newVersion=$(grep '^a2cloudVersion' "$a2cSource/install.sh" | cut -d '"' -f 2)
if [[ -f /usr/local/etc/A2CLOUD-version ]]; then
installedVersion="$(cat /usr/local/etc/A2CLOUD-version)"
read installedVersion </usr/local/etc/A2CLOUD-version
if [[ $installedVersion != *.*.* ]]; then
installedVersion="${installedVersion:0:1}.${installedVersion:1:1}.${installedVersion:2}"
fi