mirror of
https://gitea.blesmrt.net/mikaela/shell-things.git
synced 2024-11-09 18:19:23 +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"
|
||||
last --hostlast --dns --present $(date +%R) --fullnames --system --time-format notime
|
||||
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
|
||||
)
|
||||
|
6
rc/zshrc
6
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"
|
||||
last --hostlast --dns --present $(date +%R) --fullnames --system --time-format notime
|
||||
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