Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the 'Reposting to correct HTML' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Reposting to correct HTML
Authored by: jluster on Apr 16, '02 12:11:44AM

This script is a bit ... well ... overly complicated. Why not just using a "for IP in `cat ${IPFILE}`" instead of the complicated mover routine? And why not simply make it a StartupItem and let it read the whole kaboozle from hostinfo, add a key named 'IP_ADDRESSES' and fill it with colon delimited values which you then split using cut, awk, sed, or something similar?

[ Reply to This | # ]
Overly complicated scripting ;p
Authored by: evands on Apr 16, '02 12:55:28AM

For some purposes, that probably would be more elegant... the fashion of the script was needed because of the need I had to actually rotate through a list (rather than just searching it); if I run the script twice, I don't want to come up with the same IP.
Anyhoo, the important part is really the ipconfig and route stuff in the middle, which I certainly didn't find in any clear documentation anywhere (no man info on ipconfig, among other things)... the script was my own application of it. *shrug* took me a while to get working right, so I thought I'd share in case someone had a similar need.

[ Reply to This | # ]