mirror of
https://gitea.blesmrt.net/mikaela/shell-things.git
synced 2024-11-25 04:29:29 +01:00
{bash,zsh}rc: handle Kali not having last out of the box
This commit is contained in:
parent
9473b1f988
commit
bcce27ac4a
@ -144,7 +144,12 @@ if hash lsb_release 2> /dev/null; then
|
||||
printf "\n"
|
||||
printf "$(uptime --pretty)\t$(uptime)\n"
|
||||
printf "\nPresent:\n"
|
||||
if hash who 2> /dev/null; then
|
||||
who --heading --lookup --mesg --users
|
||||
elif hash last 2> /dev/null; then
|
||||
last --hostlast --dns --present $(date +%R) --fullnames --system --time-format notime
|
||||
fi
|
||||
|
||||
printf "\n"
|
||||
df / $HOME --human-readable --output=source,fstype,size,used,avail,pcent | uniq
|
||||
)
|
||||
|
4
rc/zshrc
4
rc/zshrc
@ -37,7 +37,11 @@ if hash lsb_release 2> /dev/null; then
|
||||
printf "\n"
|
||||
printf "$(uptime --pretty)\t$(uptime)\n"
|
||||
printf "\nPresent:\n"
|
||||
if hash who 2> /dev/null; then
|
||||
who --heading --lookup --mesg --users
|
||||
elif hash last 2> /dev/null; then
|
||||
last --hostlast --dns --present $(date +%R) --fullnames --system --time-format notime
|
||||
fi
|
||||
printf "\n"
|
||||
df / $HOME --human-readable --output=source,fstype,size,used,avail,pcent | uniq
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user