Rev for Gnome Shell 3.8, borrowing heavily from Ssh Provider plugin