Well, there is no distro independent command to give you the distro version. You can get detailed information about the kernel you are running with:
If you just want the kernel version number it's
The slapt-get command above is not distro dependent. It works perfectly well on any system using Slackware or Tukaani packages on which slapt-get is installed. There is no command that will work on all distros since package management systems vary. For example, on a system using rpm (Red Hat) package management system you could get the same result by typing:
rpm -qa | grep <packagename>
It's similar, as you can see. If you're on a Red Hat Enterprise Linux system the command to get the version number is:
That's also similar but obviously distro dependent.