Fix unbound variable errors
This commit is contained in:
@@ -35,10 +35,10 @@ step_20() {
|
||||
error -e "No configuration file found"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -z $FR_BACKUP ] ; then
|
||||
if [ -n "$FR_BACKUP" ] ; then
|
||||
exe mkdir -p "$FR_BACKUP"
|
||||
fi
|
||||
if [ ! -z "$1" ] ; then
|
||||
if [ -n "${1:-}" ] ; then
|
||||
tempRoot="$1"
|
||||
else
|
||||
tempRoot="$FR_LOC"
|
||||
@@ -61,7 +61,7 @@ step_20() {
|
||||
|
||||
step_22_info() {
|
||||
shift
|
||||
if [ -z $1 ] ; then
|
||||
if [ -z "${1:-}" ] ; then
|
||||
echo -n "Get latest version from github"
|
||||
if ! contextHelp ; then
|
||||
echo ": $(curl --silent "$latestUrl" | grep -Po '"tag_name": "\K.*?(?=")')"
|
||||
@@ -76,7 +76,7 @@ step_22_alias() { echo "upgrade"; }
|
||||
step_22() {
|
||||
shift # don't need step number
|
||||
local latestVersion=
|
||||
if [ ! -z $1 ] ; then
|
||||
if [ -n "${1:-}" ] ; then
|
||||
latestVersion="$1"
|
||||
else
|
||||
latestVersion=$(curl --silent "$latestUrl" | grep -Po '"tag_name": "\K.*?(?=")')
|
||||
|
Reference in New Issue
Block a user