#=================================== # Get today's horoscope # get sign hsign="" hsign="virgo" hsign=$(zenity --entry \ --title="Daily Horoscope" \ --text="Enter your _sign:" \ --entry-text "$hsign") #------------------------------------------- # output data # character width required for information box cw=38 #create data file (datadir and file name can be changed to your needs. datadir="/home/eddie/signs" filename="$datadir/th" # make sure hsign is uppercase hsign="`echo $hsign|tr '[a-z]' '[A-Z]'`" cat $datadir/$hsign > $filename echo -n "Today's date: " >> $filename date +%D >> $filename echo "Today's horoscope for:" >> $filename lynx -width 1000 -dump "http://www.creators.com/lifestylefeatures/horoscopes/horoscopes-by-holiday.html" | grep $hsign | fold -sw $cw >> $filename #output zenity --text-info --filename=$filename #remove unneeded file rm $filename