Ups! “(gnome-ssh-askpass:14185): Gtk-WARNING **: cannot open display”

You may get that error when trying to push with GIT:

$ git push origin master
(gnome-ssh-askpass:14185): Gtk-WARNING **: cannot open display:

GIT is trying to open the GNOME password dialog… which is not available through terminal.

To fix it, just change the GIT_ASKPASS variable:

$ export GIT_ASKPASS=""
$ git push origin master
Password: