19 Sep 2005
On a slashdot thread I was discussing whether I should roll my own data structure or try to use one of the many, many Sun data structures.
Someone recommended this book.
I’m sure you have seen something like this when you have connected to a ssh host.
The authenticity of host 'host (188.8.131.52)' can't be established.
RSA key fingerprint is 44:99:ff:33:66:88:cc:66:aa:22:00:00:ee:11:99:33.
Are you sure you want to continue connecting (yes/no)?
Great. Now what? What to do with that cryptic garbage up top? Log into the box or call the admin over the phone and verify the key.
$ ssh-keygen -l -f /etc/ssh/ssh_host_key.pub
When you paste a block of text into a Putty window, many times you’ll get an increasing number of leading tabs. Not so if you use gnome-terminal (IIRC). Quite annoying in a Windows world.
Strip tabs and spaces out from current position to the end of the file with:
Or perhaps you only want a small block in the middle of the file changed. First, turn on line numbers.
Then search and replace on specific line numbers (in this example lines 15 through 41).
Then use Ctrl-V (down arrow or h,j,k,l keys to select block) and hit “>” to re-indent. Works much better than reformatting by hand.