mirror of
https://github.com/dehydrated-io/dehydrated.git
synced 2026-01-13 15:13:33 +01:00
operating system name is wrong in command_version() #450
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ghost on GitHub (Dec 2, 2019).
When running dehydrated with the -v parameter, I noticed that the operating system name is broken:
The problem appears in the command_version() function, in the following line:
Apparently, it reads the /etc/issue file, which in RHEL/CentOS/Fedora systems looks like this:
Since dehydrated does not expand "\S", it appears as-is.
Maybe, on Linux distros using systemd, it would be better to parse the requred /etc/os-release file?
references:
https://www.freedesktop.org/software/systemd/man/os-release.html
https://unix.stackexchange.com/questions/351557/on-what-linux-distributions-can-i-rely-on-the-presence-of-etc-os-release
@ghost commented on GitHub (Mar 25, 2020):
no interest, closing.