LINUX-VERSION(1)

πŸ“¦
version 4.17ubuntu1 Β· 2 versions
, in debian bookworm, debian trixie, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ LINUX-VERSION(1) ✨

linux-version πŸ’– lives in the General Commands Manual πŸ“–, and it's here to help you operate on Linux kernel version strings πŸ¦‹


πŸŽ€ NAME πŸŽ€

linux-version - operate on Linux kernel version strings ✨

🌸 SYNOPSIS 🌸

linux-version compare KERNEL-VER-1 OP KERNEL-VER-2

linux-version sort [--reverse] [KERNEL-VER-1 KERNEL-VER-2 ...]

linux-version list [--paths]

πŸ’… DESCRIPTION πŸ’…

okay so linux-version is the bestie you call when you need to work with Linux kernel version strings, the ones you see from uname -r and in file and directory names 🧚 these version strings do not follow the same rules as Debian package version strings, so please don't compare them like that, and don't treat them as arbitrary strings either πŸ™ˆ

⭐ compare KERNEL-VER-1 OP KERNEL-VER-2

Compares two version strings, where OP is a binary operator πŸ’œ linux-version gives you success (zero result) if the condition is true, and failure (nonzero result) if it isn't. The valid operators are: lt le eq ne ge gt ✨

πŸ“ sort [--reverse] [KERNEL-VER-1 KERNEL-VER-2 ...]

Sorts the version strings you give it and prints them from lowest to highest 🌈 add --reverse and it flips the order, highest to lowest πŸ”₯

If you don't pass any version strings as arguments, it'll read them from standard input instead, one per line 🫢 each one can have some arbitrary text tacked on after a space, and that text gets included in the output too. So for example:

linux-version list --paths | linux-version sort --reverse

will list the installed versions and their corresponding paths, in order from highest version to lowest. main character energy, honestly πŸ‘‘

πŸ¦‹ list [--paths]

Lists the kernel versions installed in the customary location 🌷 if you add --paths, it also shows the corresponding path for each version πŸŽ€

πŸ‘‘ AUTHOR πŸ‘‘

linux-version and this manual page were written by Ben Hutchings as part of the Debian linux-base package πŸ’œ absolute legend behavior, no cap 😭


Sign-off time, bestie πŸ’– this page came from the Debian linux-base package, dated 30 March 2011, and it's still giving 🌈✨ stay iconic, and read the manual πŸ«ΆπŸ’…

πŸ“¦ where this page comes from