kernel/scripts/pahole-version.sh
sevki c9e1dba412 chore(ci): setup github actions and workflows
setup CI/CD for kernel development
- added CodeQL for code scanning
- every pr is built as an image and is available for
  30days on https://oklinux.dev
- tagged and released on github for now

Signed-off-by: sevki <s@sevki.io>
2024-03-15 21:46:24 +00:00

14 lines
269 B
Bash
Executable file

#!/bin/sh
# SPDX-License-Identifier: GPL-2.0
#
# Usage: $ ./pahole-version.sh pahole
#
# Prints pahole's version in a 3-digit form, such as 119 for v1.19.
if [ ! -x "$(command -v "$@")" ]; then
echo 0
exit 1
fi
"$@" --version | sed -E 's/v([0-9]+)\.([0-9]+)/\1\2/'