From be403aea3a9b032a00c4d663a8fc330c8e7f7df9 Mon Sep 17 00:00:00 2001 From: sctech <100468871+sctech-tr@users.noreply.github.com> Date: Tue, 3 Sep 2024 12:20:13 +0300 Subject: [PATCH] Update betterfetch.sh --- betterfetch.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/betterfetch.sh b/betterfetch.sh index 32fe776..39fbd29 100644 --- a/betterfetch.sh +++ b/betterfetch.sh @@ -37,7 +37,10 @@ fi # the meat and potatoes, actual fetch # only set these if they are not already set by the config file -[ -z "$os" ] && . /etc/os-release 2>/dev/null || export os="Unknown" +if [ -z "$os" ]; then + . /etc/os-release 2>/dev/null + os=$PRETTY_NAME # Use PRETTY_NAME or NAME +fi [ -z "$host" ] && host=$(cat /proc/sys/kernel/hostname) [ -z "$kernel" ] && kernel=$(sed "s/version // ; s/ (.*//" /proc/version) [ -z "$uptime" ] && uptime=$(uptime -p 2>/dev/null | sed "s/up //")