diff options
author | Justin M. Forbes <jforbes@fedoraproject.org> | 2020-08-12 08:03:24 -0500 |
---|---|---|
committer | Justin M. Forbes <jforbes@fedoraproject.org> | 2020-08-12 08:03:24 -0500 |
commit | 47a895f435cccb2cb14eb5d0c52d2f6d4d904907 (patch) | |
tree | 628be9cf983bcdfedd940131f8f7187020cff5f2 /scripts/kernel-version.sh | |
parent | 29d3f64f7e887d5cf9ae5f496febe5954fc49117 (diff) | |
download | kernel-47a895f435cccb2cb14eb5d0c52d2f6d4d904907.tar.gz kernel-47a895f435cccb2cb14eb5d0c52d2f6d4d904907.tar.xz kernel-47a895f435cccb2cb14eb5d0c52d2f6d4d904907.zip |
Linux v5.8.1
Signed-off-by: Justin M. Forbes <jforbes@fedoraproject.org>
Diffstat (limited to 'scripts/kernel-version.sh')
-rw-r--r-- | scripts/kernel-version.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/kernel-version.sh b/scripts/kernel-version.sh new file mode 100644 index 000000000..e2ec93a5a --- /dev/null +++ b/scripts/kernel-version.sh @@ -0,0 +1,8 @@ +VER=$(grep patch sources | head -n1 | awk '{ print $2 }' | sed s/patch-// | sed s/-git.*// | sed s/.xz// | tr -d "()") + +if [ -z "$VER" ] ; +then + VER=$(grep linux sources | head -1 | awk '{ print $2 }' | sed s/linux-// | sed s/.tar.xz// | tr -d "()") +fi + + |