That was the final piece of the puzzle, the only major feature that was not working. Now my Emacs environment is complete! Hooray!
As usual, all the information needed to get this running was out there, but poorly organized. Basically, it comes down to the following two points:
1. NTEmacs can only use cygwin ssh-agent if launched from cygwin bash. This is not a problem; under Windows I currently use the following VB script to launch:
WScript.CreateObject("WScript.Shell").Run "c:\cygwin\bin\bash -l -c /usr/bin/emacs", 0, false
1a. Alternatively, one can use PuTTY with plink protocol and the PuTTY agent; search EmacsWiki for info on how to do this; this PDF helps.
2. Assuming we are going the cygwin route, this is what's needed in .emacs
(setq tramp-default-method "ssh")
(nconc (cadr (assq 'tramp-login-args (assoc "ssh" tramp-methods))) '(("bash" "-i")))
(setcdr (assq 'tramp-remote-sh (assoc "ssh" tramp-methods)) '("bash -i"))
This is it!
And now, for computing tweak of the day: I like to only press tab once in order to display candidate list in bash tab completion. I think it makes significant usability difference. Here's how to turn it on:
echo "set show-all-if-ambiguous on # for single tab press completion" >> ~/.inputrc