Search notes:
/etc/os-release
The content of such a file might be:
NAME="Ubuntu"
VERSION="16.04 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
UBUNTU_CODENAME=xenial
The idea of this file is that it can be «sourced» in a shell which sets the shell variables accordingly:
$ source /etc/os-release
$ echo "Debian version is $VERSION"
Debian version is 11 (bullseye)