Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

[Feature Suggestion] Support for codenames. From Debian and other common distros. #2437

Open
dewcansam opened this issue Jan 13, 2024 · 2 comments

Comments

@dewcansam
Copy link

[Feature Suggestion] Support for codenames. From Debian and other common distros.

Description

Add support for codenames. From Debian, Ubuntu, Mint and others.
I have always had to look up my version then google which codename was used. Although I finally found a webpage for "Distro Code Names" and bookmarked it.
I was trying to install docker and saw a command I had never seen before and it's output. I was astounded to find that getting the code name was as easy as:
apt-cache policy vim
I am really terrible with regex (got something to learn) or else I would create a alias function to pull it out.

I studied the wiki but was unable to find any way to garner the codename. If there is a way please enlighten me. If not the please include it in the neofetch output. It would make things so much easier. And it seems so easy to gather the codename from the apt-cache policy output.

Output from neofetch computer 1:
OS: Linux Mint 19.3 Tricia x86_64
Output from apt-cache policy computer 1 :
bionic/main amd64
Example from computer 1. In this case the codename "bionic" does not match the neofetch "Tricia" output.

Example from computer 2.
Output from neofetch computer 2:
OS: Linux Mint 20.3 x86_64
Output from apt-cache policy computer 2:
focal/main amd64
Example from computer 2. In this case the codename "focal" is NOT displayed at all in the neofetch output.

@tnsicdr
Copy link

tnsicdr commented Jan 14, 2024

You can pull it by running the following:

. /etc/os-release | printf '%s\n' "$VERSION"

@dewcansam
Copy link
Author

Unfortunately I could not get an output from that command. But, yes the information is there. I did just a simple grep for 'codename'.
cat /etc/os-release | grep -i "codename"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants