Simply use lsb_release
:
$ lsb_release -sr
12.04
See the man page for all available options. Note that not all platforms or Linux distributions have lsb_release
.
3
solved Shell script to get the OS version [closed]
Simply use lsb_release
:
$ lsb_release -sr
12.04
See the man page for all available options. Note that not all platforms or Linux distributions have lsb_release
.
3
solved Shell script to get the OS version [closed]