From 25d63b64947be302c0284cab8f25908fad4b2e9d Mon Sep 17 00:00:00 2001 From: Masanori Ogino Date: Wed, 9 Mar 2022 09:39:56 +0900 Subject: [PATCH] neofetch: Priorize /etc/os-release From os-release(5): > The file /etc/os-release takes precedence over /usr/lib/os-release. > Applications should check for the former, and exclusively use its > data if it exists, and only fall back to /usr/lib/os-release if it > is missing. Applications should not read data from both files at the > same time. Signed-off-by: Masanori Ogino --- neofetch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neofetch b/neofetch index 48b96d21..f14accbc 100755 --- a/neofetch +++ b/neofetch @@ -1022,8 +1022,8 @@ get_distro() { -f /etc/lsb-release ]]; then # Source the os-release file - for file in /etc/lsb-release /usr/lib/os-release \ - /etc/os-release /etc/openwrt_release; do + for file in /etc/lsb-release /etc/os-release \ + /usr/lib/os-release /etc/openwrt_release; do source "$file" && break done