On Sat, Sep 06, 2003 at 10:03:09PM -0400, Jeff Elkins wrote: > I'm doing a lot of work with a Sharp Zaurus which requires several re-flashes > of the box daily - With my initrd.bin, ssh keys on the Z regenerate with each > flash. As a consequence, my host .ssh/known_hosts is frequently outdated and > I must edit it to remove references to z,xxx.xxx.xxx.xxx. > > I'd like to gen up a script to nuke references in .ssh/known_hosts to the > Zaurus. It's trivial to edit known_hosts, but I'd like to eliminate this > step.
perl -ni.bak -e 'print unless /^z,xxx.xxx.xxx.xxx/' ~/.ssh/known_hosts -- Dave Carrigan Seattle, WA, USA [EMAIL PROTECTED] | http://www.rudedog.org/ | ICQ:161669680 UNIX-Apache-Perl-Linux-Firewalls-LDAP-C-C++-DNS-PalmOS-PostgreSQL-MySQL
pgp00000.pgp
Description: PGP signature