Skip to content
linux-seblu.install 921 B
Newer Older
Seblu's avatar
Seblu committed
# vim:set ts=2 sw=2 ft=sh et:

Seblu's avatar
Seblu committed
_warning_msg() {
  # compute the kernel version from the package version
  local kver=${1%-*}
  local kver=${kver/_/-}-seblu
Seblu's avatar
Seblu committed

  # advertise if you update the current running kernel
Seblu's avatar
Seblu committed
  if [[ "$kver" == "$(uname -r)" ]]; then
Seblu's avatar
Seblu committed
    echo '********************************************************************************'
    echo '********************************************************************************'
Seblu's avatar
Seblu committed
    echo "****** YOU HAVE ${2^^} THE CURRENTLY RUNNING KERNEL ** REBOOT IMMEDIATLY ******"
Seblu's avatar
Seblu committed
    echo '********************************************************************************'
    echo '********************************************************************************'
  fi
}

Seblu's avatar
Seblu committed
# arg 1:  the new package version
# arg 2:  the old package version
post_upgrade() {
  _warning_msg "$2" 'updated'
Seblu's avatar
Seblu committed
}

# arg 1:  the old package version
post_remove() {
  _warning_msg "$1" 'removed'
Seblu's avatar
Seblu committed
}