custom SSH login

Post Reply
zemerdon
Site Admin
Posts: 377
Joined: Mon Jan 23, 2023 8:13 pm

custom SSH login

Post by zemerdon »

chmod +x 01-custom
zemerdon@nvr:~$ cat /etc/update-motd.d/01-custom

#!/bin/sh
echo "GENERAL SYSTEM INFORMATION"
#/usr/bin/screenfetch
/usr/bin/neofetch
echo
echo "SYSTEM DISK USAGE"
export TERM=xterm; inxi -D
echo
echo "CURRENT WEATHER AT THE LOCATION"
# Show weather information. Change the city name to fit your location
ansiweather -l brisbane
zemerdon
Site Admin
Posts: 377
Joined: Mon Jan 23, 2023 8:13 pm

Re: custom SSH login

Post by zemerdon »

if neofetch / fastfetch displays no colour, append the following to your .bashrc file at the bottom.

Code: Select all

# Run fastfetch on interactive terminal login
if [[ $- == *i* ]]; then
    fastfetch
fi

Code: Select all

# Run fastfetch on interactive terminal login
if [[ $- == *i* ]]; then
echo "GENERAL SYSTEM INFORMATION"
/usr/bin/fastfetch
echo
echo "SYSTEM DISK USAGE"
export TERM=xterm; inxi -D
echo
fi
zemerdon
Site Admin
Posts: 377
Joined: Mon Jan 23, 2023 8:13 pm

latest fastfetch (neofetch replacement)

Post by zemerdon »

Post Reply