http://www.perlmonks.org?node_id=512315

I put this together today at work, it's nothing special but i think it's pretty neat for a first perl script. I hope ya'll like it.
#!/usr/bin/perl # # To set up ssh keys # # set up "global" vars $home = $ENV{"HOME"}; $remotemachine = $ARGV[0]; $user = $ENV{"USER"}; # see if keys exist if (-e !"/$home/.ssh/id_dsa.pub") { `ssh-keygen -t dsa` }; `scp /$home/.ssh/id_dsa.pub $remotemachine://home/$user/.ssh/authorize +d_keys2`; `ssh-agent sh -c 'ssh-add < /dev/null && bash'`; `ssh $remotemachine`; exit (0);