#!/bin/sh # Linux Vulnerability Mitigation # Copyright (C) 2026 Daniel Baumann # # SPDX-License-Identifier: PD # # This program is free software: you have unlimited permission # to copy, distribute and modify it. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. set -e PROGRAM="linux-vulnerability-mitigation" COMMAND="$(basename "${0}")" SHARE="/usr/share/${PROGRAM}" Parameters () { GETOPT_LONGOPTIONS="help," GETOPT_OPTIONS="h," PARAMETERS="$(getopt --longoptions ${GETOPT_LONGOPTIONS} --name="${COMMAND}" --options ${GETOPT_OPTIONS} --shell sh -- "${@}")" # shellcheck disable=SC2181 if [ "${?}" != "0" ] then echo "'${COMMAND}': getopt exit" >&2 exit 1 fi eval set -- "${PARAMETERS}" while true do case "${1}" in -h|--help) Usage ;; --) shift 1 break ;; *) echo "'${COMMAND}': getopt error" >&2 exit 1 ;; esac done } Usage () { echo "Usage: ${PROGRAM} ${COMMAND} [-h|--help]" >&2 echo echo "See ${PROGRAM}-${COMMAND}(1), ${PROGRAM}(1) and ${PROGRAM}(7) for more information." } Parameters "${@}" # Run cat "${SHARE}/VERSION.txt"