docs: update
This commit is contained in:
parent
4c20333450
commit
17f6791ffa
16
pfetch
16
pfetch
|
@ -79,6 +79,12 @@ log() {
|
|||
: $((info_height+=1))
|
||||
}
|
||||
|
||||
# Simple function to avoid '>/dev/null' spam.
|
||||
# This checks to see if a command is in '$PATH'.
|
||||
has() {
|
||||
command -v "$1" >/dev/null
|
||||
}
|
||||
|
||||
get_title() {
|
||||
# Username is retrieved by first checking '$USER' with a fallback
|
||||
# to the 'whoami' command.
|
||||
|
@ -110,6 +116,8 @@ get_os() {
|
|||
|
||||
case $os in
|
||||
Linux*)
|
||||
has lsb_release && distro=$(lsb_release -sd)
|
||||
|
||||
# Disable warning about shellcheck not being able
|
||||
# to read '/etc/os-release'. This is fine.
|
||||
# shellcheck source=/dev/null
|
||||
|
@ -117,8 +125,8 @@ get_os() {
|
|||
|
||||
# Special cases for distributions which don't follow.
|
||||
# the '/etc/os-release' "standard".
|
||||
command -v crux >/dev/null && distro=$(crux)
|
||||
command -v guix >/dev/null && distro='Guix System'
|
||||
has crux && distro=$(crux)
|
||||
has guix && distro='Guix System'
|
||||
;;
|
||||
|
||||
Darwin*)
|
||||
|
@ -214,10 +222,6 @@ get_uptime() {
|
|||
}
|
||||
|
||||
get_pkgs() {
|
||||
# Simple function to avoid '>/dev/null' spam.
|
||||
# This checks to see if a command is in '$PATH'.
|
||||
has() { command -v "$1" >/dev/null; }
|
||||
|
||||
# This works by first checking for which package managers are
|
||||
# isntalled and finally by printing each package manager's
|
||||
# package list with each package one per line.
|
||||
|
|
Loading…
Reference in New Issue
Block a user