| |||||||||||||||||||||||||||||||||||||
Wicked Cool Shell Scripts: The LibraryThere are 101 scripts discussed in this book, but in fact there are closer to 150 scripts available, in total. Here's how you can get them if you'd like. You are welcome to do this if you don't have the book, but it'll make a lot more sense if you do have "Wicked Cool Shell Scripts", of course. Note that you can also download the entire set of scripts as AllFiles.tgz. Just make sure you unpack the scripts into their own directory!
show what services are enabled with inetd and xinetd,
if they're available on the system.
send the specified signal to all processes that match a
specific process name
script checks a crontab file to ensure that it's
formatted properly. Expects standard cron notation
where min is 0-59, hr 0-23, dom is 1-31, mon is 1-12 (or names)
and dow is 0-7 (or names). Fields can have ranges (a-e), lists
separated by commas (a,c,z), or an asterisk. Note that the step
value notation of Vixie cron is not supported (e.g., 2-6/2).
simple script to run the daily, weekly and monthly
system cron jobs on a system where it's likely that
it'll be shut down at the usual time of day when
this would occur.
roll logfiles in /var/log for archival purposes.
uses a config file to allow customization of how frequently
each log should be rolled.
create either a full or incremental backup of a set of
defined directories on the system. By default, the output
file is saved in /tmp with a timestamped filename, compressed.
create a compressed archive of the specified directory
reports cumulative connection time for month/year entries
found in the system log file.
given an ftp: style URL, unwrap it, and try to obtain the file
using anonymous ftp.
report the top stories on the BBC World Service
given a URL, return all of its internal and
external links
given a word, return its definition from dictionary.com
report weather forecast, including lat/long, for zip
log in to the Boulder Public Library computer
system and show the due date of everything checked out for
the specified user. A demonstration of how to work with the
method="post" form with lynx.
given a movie title, return a list of matches, if
there's more than one, or a synopsis of the movie if there's
just one. Uses the Internet Movie Database (imdb.com)
given a currency amount, convert it into other major
currencies and show the equivalent amounts in each.
scrape the current currency exchange rates
from CNN's money and finance Web site.
given a stock ticker symbol, return its current value
from the Lycos web site
calculate the value of each stock in your holdings,
then calculate the value of your overall portfolio, based on
the latest stock market position.
track a given URL, and if it's changed since the last
visit, email the new page to the specified address.
display the CGI runtime environment, as given to any
CGI script on this system.
given a search request, log the pattern, then
feed the entire sequence to the real Yahoo search system.
html helper file for script #70, logsearch.
grab the latest column
of 'The Straight Dope' and mail it to the specified recipient
Build a Web page on-the-fly to display the latest
strip from the cartoon strip Kevin and Kell, by Bill Holbrook
(Strip referenced with permission of the cartoonist)
Process the contact us form data, email it to the designated
recipient, and return a succinct thank you message.
html helper file for script #72, contactus.cgi
dynamic web photo album utility.
display the current guestbook entries, append a
simple form for visitors to add their own comments, and
accept and process new guest entries. Works with a separate
data file that actually contains the guest data.
data file for script #74, guestbook.cgi
a simple text-based page counter, with appropriate locking
html helper file for script #75, counter
output an HTML file, replacing the sequence
---countervalue--- with the current counter value.
a tiny script that updates the counter file to
the value specified. Assumes that locking is done elsewhere.
|
| ||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||