I am trying to keep gvim as my default editor when I use VNC to my machine. But want to keep vim as my default editor when I am logged in through SSH. I am not sure how to differentiate in my .bashrc file to do this automatically. Similarly, is there a way I can know the session is through a console directly connected with my machine.
Thanks