clear
hours=`date|cut -c12-13`
if [ $hours -le 12 ]
then
echo "Good Morning"
else
if [ $hours -le 16 ]
then
echo "Good Afternoon"
elif [ $hours -le 20 ]
then
echo "Good Evening"
else
echo "Good Night"
fi
fi
Shell script to wish according to day time
- Post author:Educate
- Post published:September 18, 2023
- Post category:Shell Script
- Post comments:0 Comments