diff --git a/openup b/openup index 4f13332..28a7f73 100755 --- a/openup +++ b/openup @@ -104,7 +104,7 @@ bye_bye() { } pr() { - if [ -z "${checkmode}" ]; then + if [ -z "${checkrun}" ]; then echo "===> ${@}" fi } @@ -171,7 +171,7 @@ update_binpatches() { _BP=$(echo "${_BP}" | tr '\n' ' ') pr "Installing/updating binpatch(es)" - pkg_add ${pkg_opt} ${_BP} || bye_bye + pkg_add ${pkgopt} ${_BP} || bye_bye fi } @@ -188,7 +188,7 @@ update_pkg() { _PKG=$(echo "${_PKG}" | tr '\n' ' ') pr "Updating package(s)" - pkg_add -quz ${pkg_opt} ${_PKG} || bye_bye + pkg_add -quz ${pkgopt} ${_PKG} || bye_bye fi } @@ -252,9 +252,9 @@ do_i_need_to_reboot() { while getopts 'KSc' arg; do case ${arg} in - K) exclude_kernel=1 ;; - S) nosig=1; pkg_opt="${pkg_opt} -Dnosig -Dunsigned" ;; - c) checkmode=1 ;; + K) nokrn=1 ;; + S) nosig=1; pkgopt="${pkgopt} -Dnosig -Dunsigned" ;; + c) checkrun=1 ;; *) usage ;; esac done @@ -267,17 +267,17 @@ if [ -f ${_PID} ]; then fi echo $$ >${_PID} -[ -n "${checkmode}" -a -n "${nosig}" ] && usage +[ -n "${checkrun}" -a -n "${nosig}" ] && usage check_openupd -if [ -n "${exclude_kernel}" ]; then +if [ -n "${nokrn}" ]; then EXCLUDE_PKG="binpatch${_REL_INT}-${_ARCH}-kernel ${EXCLUDE_PKG}" fi if [ -n "${EXCLUDE_PKG}" ]; then pr "Excluded package(s)/binpatch(es): ${EXCLUDE_PKG}" fi -if [ "${checkmode}" ]; then +if [ "${checkrun}" ]; then check_vuxml else [ -z "${nosig}" ] && get_key