and now for fun with seq!
Aug. 6th, 2007 08:16 pmSo, I had a customer today that had mistakenly added a bunch of hosts en masse to a config file via a GUI tool. The tool, however, does not allow for mass removal. So, the ticket came to me.
I removed the hosts from the config file using the magic of
That
I removed the hosts from the config file using the magic of
seq!for i in `seq -w 036 1 200`; do command -rm "remove per [ticket_number]" host-complex$i.system.domain.tld; done
That
-w flag is really handy for keeping the padding zeros in place, especially since the customer had started at such a non-round number.