summaryrefslogtreecommitdiff
path: root/packaging/utils/kernelversion-short
blob: 677f7b4da280bb0d5bc7cf8957aeff98b2b2d2e8 (plain)
1
2
3
4
5
6
7
8
#! /bin/sh
# determine kernel version code, mostly for use in RPM building

awk 'BEGIN { FS = " *= *" }
	NF != 2 { next }
	$1 == "VERSION" { maj = $2 }
	$1 == "PATCHLEVEL" { mid = $2 }
	END { print maj "." mid }' $*