Export Putty Settings With a Single Command
There are many ways to export your saved settings from PuTTY. PuTTY stores its settings in your system register so in the end all the methods export the registry settings to a file that can later be imported to restore the settings. The quickest way to do this to run the following command in the Start | Run box (all one line):
regedit /e “%userprofile%\desktop\putty.reg” HKEY_CURRENT_USER\Software\Simontatham
Thats it. That is all there is to it. On your desktop you now have a file named “putty.reg” that you can copy to another machine or save as a backup for your PuTTY settings. To restore your settings just double click on the file.
Categories: Computers, Technology
Thanks for sharing! Unfortunately the command line tool doesn’t work in Vista 64 bit. The data is still there, and simple to export though. The path on my Vista machine ended up being:
HKEY_USERS\S-1-5-21-1874068349-1688302950-636360099-36883\Software\SimonTatham\PuTTY\Sessions
I’d recommend just using the find utility and searching for SimonTatham
Fantastic. Very nice indeed.
Excellent tutorial. Between my laptop, my desktop at home and my desktop at work I need these to all stay the same. This definitely helped and worked! Thanks!
Excellent method, thanks!
(although as usual the quotes need to be replaced with “regular” ones)
If you have Unix tools available, you can easily create a simple html list as well. Open putty.reg with Notepad, resave it as plain text (UTF-8) & then do:
egrep -i ‘sessions\\|HostName’ putty.txt |\
sed -e ‘s/^.*Sessions.\(.*\)]/\1/’ -e ‘s/”HostName”=”\(.*\)”/\1/’ | \
while read foo
do
if [ -z "$host" ]
then
host=$foo
else
echo “$host”
host=”"
fi
done | \
sed -e ‘s/%20/ /g’ > hosts.html
There is a simple registry hack out there (http://www.nilpo.com/2007/08/windows-xp/creating-a-custom-url-protocol-for-ssh/) that makes “ssh://” URLs useful.
regedit is not exactly a command-line tool.
An alternative way would be:
reg export HKCU\Software\Simontatham regexp.reg