I connect to a Windows Machine via SSH into a Powershell Terminal, and regularly need to made quick,small edits in text files on this Windows Computer, and others reachable via UNC syntax.

Currently I use the binary from the vim console version for windows, but it has drawing problems in my scenario: When you scroll lower than the last line in a file longer than the screen, all lines but the last disappear, and you have to force a redraw with ^L.

There is also a portable single-binary compile of nano.exe, but it has flaws, like non-functioning cursor keys. It also is pretty basic, no vi grammar, no syntax highlighting, but those I could live without for small edits.

For larger,more-involved edits on remote files I already use the excellent emacs/evil/tramp/sftp IDE running locally on my Linux.

Old Windows Versions up to 7/32bit included a very basic editor, that I used to use, but everything starting from 7/64bit does not have that editor anymore, so please don't suggest that one.

The editor vile does not even display anything over SSH in Powershell.

  • Hi Downvoter, I am new here, could you please elaborate on the reason. Or could somebody else please clue me in? Commented May 10, 2018 at 20:12

2 Answers 2


Not sure how portable it can be, and not exactly 'small', but vim does have console (including PowerShell) support.

vile and elvis might also work, though I don't know almost anything about them other than that they're vi clones which support Windows.

  • 1
    vim.exe from Win32.zip in powershell via ssh from Linux has redraw problems: When you scroll down on a larger file, all lines but the last disappear, and you have to force a manual redraw with ^L. I will add to my question that I tried that too. Thank you anyway, have a +1 Commented May 10, 2018 at 20:11
  • I tried vile, It completely fails to draw over SSH in Powershell. Both it and elvis are ancient, and do not look very maintained Commented May 10, 2018 at 20:35

Mosh is a shell designed for easy roaming, slow network connections and instant user responses

Remote terminal application that allows roaming, supports intermittent connectivity, and provides intelligent local echo and line editing of user keystrokes.

Mosh is a replacement for interactive SSH terminals. It's more robust and responsive, especially over Wi-Fi, cellular, and long-distance links.

The important thing is that it understands vi commands and predicts what will happen to show the text correctly

Get rid of network lag.

SSH waits for the server's reply before showing you your own typing. That can make for a lousy user interface. Mosh is different: it gives an instant response to typing, deleting, and line editing. It does this adaptively and works even in full-screen programs like emacs and vim. On a bad connection, outstanding predictions are underlined so you won't be misled.

If you're remoting from Windows then see this Portable Windows Mosh. You can keep a portable version of Mobaxterm which will include both mosh and vi

  • For other questions, "mosh" is a good answer, but not for mine. I'm afraid, you misunderstood. Thanks anyway for your time and effort Commented Jul 22, 2018 at 12:45
  • @AlexStragies just run a mosh server on Windows and ssh into it. You should use a 3rd party terminal like Mobaxterm, as Windows console might not support ANSI codes very well, which results in glitches when running vi
    – phuclv
    Commented Jul 28, 2018 at 9:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.