]> git.armaanb.net Git - bin.git/blobdiff - ufetch
ufetch show date, lolcat-gen custom number of runs
[bin.git] / ufetch
diff --git a/ufetch b/ufetch
index eb91b8be46ef1265edbd50af98d1d2d60403d220..a9d1744f6978975a83f651f7bbcc155db36605f3 100755 (executable)
--- a/ufetch
+++ b/ufetch
@@ -1,27 +1,23 @@
 #!/bin/sh
-# ufetch-armaan. My customized version of ufetch that doesn't print the ascii art, and doesn't spend time looking things up like the DE. Full credit goes to jschx (Joe Schillinger), the author of ufetch. <https://gitlab.com/jschx/ufetch>
+# ufetch-armaan. My customized version of ufetch that doesn't print the ascii
+# art, and focuses on information that changes often. Ufetch was written
+# by jschx (Joe Schillinger), and is ISC licensed.
+# https://gitlab.com/jschx/ufetch
 
 ## INFO
-host="$(hostname)"
-os='Debian unstable'
+host="$(cat /etc/hostname | head -n 1)"
+os="$(cat /etc/os-release | grep "PRETTY_NAME" | cut -d '"' -f 2)"
 kernel="$(uname -sr)"
-uptime="$(uptime -p | cut -d ',' -f 1-2 | tail -c +4)"
-shell="zsh"
-ui="KDE Plasma"
+uptime="$(uptime -p | sed 's/up //')"
+date="$(date +%Y-%m-%e)"
+time="$(date +%r)"
+locip="$(ip addr | grep "/24" | cut -d ' ' -f 6)"
 
 ## DEFINE COLORS
 bold='\033[1m'
-# black='\033[0;30m'
-# red='\033[0;31m'
-# green='\033[0;32m'
-# yellow='\033[0;33m'
-# blue='\033[0;34m'
-# magenta='\033[0;35m'
-# cyan='\033[0;36m'
 white='\033[0;37m'
 reset='\033[0m'
 
-# you can change these
 lc="${reset}${bold}${white}"         # labels
 nc="${reset}${bold}${white}"         # user and hostname
 ic="${reset}"                        # info
@@ -31,5 +27,6 @@ printf "${nc}${USER}${ic}@${nc}${host}${reset}
 ${lc}OS        ${ic}${os}${reset}
 ${lc}KERNEL    ${ic}${kernel}${reset}
 ${lc}UPTIME    ${ic}${uptime}${reset}
-${lc}SHELL     ${ic}${shell}${reset}
-${lc}DE        ${ic}${ui}${reset}"
+${lc}DATE      ${ic}${date}${reset}
+${lc}TIME      ${ic}${time}${reset}
+"