Category Archives: answers

Scripting class, answers 1

1. In firefox, right click on an image and do Copy link location. Then use that link in your script. {1..21} is shorthand for the space separated list from 1 to 21, i.e.: “1 2 3 4 5 6 7 … Continue reading

Posted in answers, scripting | Leave a comment

Bash Guide for Beginners, chapter 4 solutions

Solutions to: http://tldp.org/LDP/Bash-Beginners-Guide/html/sect_04_05.html 1. grep bash /etc/passwd | cut -d: -f1grep bash /etc/passwd | cut -d: -f1 2. grep "^daemon" /etc/groupgrep "^daemon" /etc/group 3. grep –invert-match "^daemon" /etc/groupgrep –invert-match "^daemon" /etc/group 4. info with line numbers: grep -n localhost /etc/hostsgrep … Continue reading

Posted in answers, scripting | 1 Comment