mirror of
https://github.com/G2-Games/welcome.sh.git
synced 2025-04-19 21:42:53 -05:00
Added toggle for "good" instead of "It's" for greetings
This commit is contained in:
parent
45e00f997d
commit
87a509c991
1 changed files with 9 additions and 3 deletions
12
welcome.sh
12
welcome.sh
|
@ -33,15 +33,20 @@ clock () {
|
||||||
greeting () {
|
greeting () {
|
||||||
# Set the hour
|
# Set the hour
|
||||||
hour=$(date +%H)
|
hour=$(date +%H)
|
||||||
|
greet="It's"
|
||||||
|
|
||||||
|
if [ "$greetingtype" = "on" ]; then
|
||||||
|
greet="Good"
|
||||||
|
fi
|
||||||
|
|
||||||
if [ $hour -le 11 ] && [ $hour -gt 6 ]; then
|
if [ $hour -le 11 ] && [ $hour -gt 6 ]; then
|
||||||
echo -en "It's ${MORN}morning${NCOL}. "
|
echo -en "$greet ${MORN}morning${NCOL}. "
|
||||||
elif [ $hour -eq 12 ]; then
|
elif [ $hour -eq 12 ]; then
|
||||||
echo -en "It's ${AFTN}noon${NCOL}. "
|
echo -en "It's ${AFTN}noon${NCOL}. "
|
||||||
elif [ $hour -le 16 ] && [ $hour -gt 12 ]; then
|
elif [ $hour -le 16 ] && [ $hour -gt 12 ]; then
|
||||||
echo -en "It's ${AFTN}afternoon${NCOL}. "
|
echo -en "$greet ${AFTN}afternoon${NCOL}. "
|
||||||
elif [ $hour -le 19 ] && [ $hour -gt 17 ]; then
|
elif [ $hour -le 19 ] && [ $hour -gt 17 ]; then
|
||||||
echo -en "It's ${EVEN}evening${NCOL}. "
|
echo -en "$greet ${EVEN}evening${NCOL}. "
|
||||||
else
|
else
|
||||||
echo -en "It's ${NIGH}night${NCOL}. "
|
echo -en "It's ${NIGH}night${NCOL}. "
|
||||||
fi
|
fi
|
||||||
|
@ -193,6 +198,7 @@ randgreeting="off" #< Turn the random greetings on (eg. "Hello <user>, Hi <user
|
||||||
twelvehour="on" #< Switch between 12 and 24 hour time (eg. 8:00pm vs 20:00)
|
twelvehour="on" #< Switch between 12 and 24 hour time (eg. 8:00pm vs 20:00)
|
||||||
rechargenotif="off" #< Notify that you should recharge if below 15%
|
rechargenotif="off" #< Notify that you should recharge if below 15%
|
||||||
flatpakupd="off" #< Check for flatpak updates, this slows startup down A LOT
|
flatpakupd="off" #< Check for flatpak updates, this slows startup down A LOT
|
||||||
|
greetingtype="on"
|
||||||
|
|
||||||
welcome
|
welcome
|
||||||
greeting
|
greeting
|
||||||
|
|
Loading…
Reference in a new issue