Hi, I;m trying to make a simple bash script to google the definition of a word (http://google.com/search?q=define:), and I want it to display the results in text, or even just the first result. So far, it'll just open up the search results page in my browser. Here's the script so far:
Any suggestions on reading the html, accessing the right words, and displaying it as plain text?
Code:
echo 'Enter a word to define: '
read F1
F=`echo $F1 | sed s/\ /+/g`
open "http://google.com/search?q=define:$F"
Any suggestions on reading the html, accessing the right words, and displaying it as plain text?