On Tue, Jun 21, 2005 at 07:06:08PM -0400, Marty wrote: > Roberto C. Sanchez wrote: > > >-------- 8< -------- > >#!/bin/sh > >EMAIL="[EMAIL PROTECTED]" > >lynx -dump http://checkip.dyndns.org |sed -n '/Current/s/.*: > >\([0-9]*\.[0-9]*\.[0-9]*\.[0-9]*\)/\1/p' | /usr/bin/Mail -s "IP address as > >of > >`date`" $EMAIL > >-------- 8< -------- > >HTH, > >-Roberto > > FWIW this site requires no parsing: > > wget http://www.whatismyip.org/ -qO - | html2text | mail [etc etc ....] > >
FWIW, sed is a required package and thus guaranteed to be present on any Debian system, while html2text is optional. $ apt-cache show sed |grep Priority Priority: required $ apt-cache show html2text |grep Priority Priority: optional If the job can be done with Priority `required' or `important' tools, there is a much better chance of the script being portable. -Roberto -- Roberto C. Sanchez http://familiasanchez.net/~sanchezr
pgp8g8BU2V34P.pgp
Description: PGP signature