Skip to main content

Posts

Showing posts from March, 2013

I made a GIF!

SSH options for scripting

Suggested SSH/SFTP/SCP options when creating a script: Do not store the remote host's SSH public keyfile for later "-o UserKnownHostsFile=/dev/null" Do not check for the remote host's SSH public keyfile in known_hosts "-o StrictHostKeychecking=no" Do not check localhost's SSH public keyfile in known_hosts "-o NoHostAuthenticationForLocalhost=yes" Do not attempt authenticate using a password or prompt for password "-o PasswordAuthentication=no" Attempt authenticate using the specified SSH private key file (default file shown) "-i $HOME/.ssh/id_rsa" All options above included in a test command: touch $HOME/test.txt; \ scp \ -o UserKnownHostsFile=/dev/null \ -o StrictHostKeychecking=no \ -o NoHostAuthenticationForLocalhost=yes \ -o PasswordAuthentication=no \ -i $HOME/.ssh/id_rsa \ $HOME/test.txt \ $USERNAME@localhost:test-`date +%Y%m%d-%H%M%S%N`.txt The command above presumes

LinkedIn URL shortener

While you can customize your LinkedIn page's URI to make it easier to remember, it does not make it significantly shorter. LinkedIn has arranged a custom bit.ly domain 'linkd.in' to handle shortening linkedin.com   URIs.  Naturally, the shortened URI version is great for business cards and other applications where space is restricted.  For example, my professional profile on LinkedIn is: http://www.linkedin.com/in/jantonacci/ and when shortened becomes: http://linkd.in/X5PiqU  .

Eugoogly for Google Reader

Well this sucks. I had not intended to start my day mourning the (impending) loss of a dear friend.  What is next?  Euthanize Blogger? I need an on-line feed reader with all my news and blogs integrated in one secure site. Twitter is NOT a substitute. Official Google Reader Blog: Powering Down Google Reader : Posted by Alan Green, Software Engineer We have just announced on the Official Google Blog that we will soon retire Google Reader (the...

4 8 1516 23 42... LOST

Display the (in)famous LOST television series numbers on the command line.  Perl one-liner to exec with ActiveState PERL on Windows.   perl -e "$|=1;@lostNumbers=('4','8', '15', '16', '23', '42'); while (1) { print ' ' x (rand(35) + 1), ($lostNumbers[int rand @lostNumbers]) }" As a script, lostNumbers.pl, you can get a bit fancier with different subroutines... #!/usr/bin/perl -w use warnings; use strict;  #&lostNumRandFast; #&lostNumRand; #&lostNumRandGapsFast; &lostNumRandGaps; #&lostNumRandStart;  sub lostNumRandFast { $| = 1; my @lostNumbers=('4', '8', '15', '16', '23', '42'); my $iterations=65535; while ($iterations--) { print ' ' x (rand(35) + 1); print ($lostNumbers[int rand @lostNumbers] ); } } sub lostNumRand { $| = 1; my @lostNumbers=('4', '8', '15', '16', '23