Merge branch 'fix/explorer/os_version/old-freebsd' into 'master'
explorer/os_version: fix for FreeBSD < 10.0 (again) See merge request ungleich-public/cdist!1017
This commit is contained in:
commit
841ebb9b88
1 changed files with 8 additions and 1 deletions
|
@ -101,7 +101,14 @@ in
|
||||||
freebsd)
|
freebsd)
|
||||||
# Apparently uname -r is not a reliable way to get the patch level.
|
# Apparently uname -r is not a reliable way to get the patch level.
|
||||||
# See: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=251743
|
# See: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=251743
|
||||||
freebsd-version
|
if command -v freebsd-version >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
# get userland version
|
||||||
|
freebsd-version -u
|
||||||
|
else
|
||||||
|
# fallback to kernel release for FreeBSD < 10.0
|
||||||
|
uname -r
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
*bsd|solaris)
|
*bsd|solaris)
|
||||||
uname -r
|
uname -r
|
||||||
|
|
Loading…
Reference in a new issue