Exit with success if everything was ok
This commit is contained in:
parent
03178436a9
commit
06b03ea27c
|
@ -63,7 +63,7 @@ debug_message() { # {{{
|
|||
|
||||
}
|
||||
# }}}
|
||||
is_apt_upgrade_absent() { # {{{
|
||||
is_apt_upgrade_absent() { # {{{
|
||||
|
||||
## Count the number of upgradable packages and substract 1 for the header
|
||||
local_apt_upgrade_number="$(apt list --upgradable \
|
||||
|
@ -87,7 +87,7 @@ APT upgrade available for this system: ${RED}${local_apt_upgrade_number:=/dev/nu
|
|||
|
||||
}
|
||||
# }}}
|
||||
is_apt_upgrade_present() { # {{{
|
||||
is_apt_upgrade_present() { # {{{
|
||||
|
||||
## Count the number of upgradable packages and substract 1 for the header
|
||||
local_apt_upgrade_number="$(apt list --upgradable \
|
||||
|
@ -125,11 +125,12 @@ main() { # {{{
|
|||
## If APT package upgrade is available
|
||||
### Disable SGE queue
|
||||
is_apt_upgrade_present \
|
||||
&& sh "${disable_host_queue_script}"
|
||||
&& sh "${disable_host_queue_script}" \
|
||||
&& exit 0
|
||||
|
||||
}
|
||||
# }}}
|
||||
|
||||
main
|
||||
|
||||
exit 0
|
||||
exit 255
|
||||
|
|
Loading…
Reference in New Issue