Using Vim with Midnight Commander PDF Print E-mail
Written by Fr. Robert Bower   
Friday, 21 January 2011 08:51

This article is for us old school types. Midnight Commander is a great file manager. Features include an ftp client, a file viewer, and a file editor. While the online file viewer and file editor are good but if you want use a different command line text editor you can configure midnight commander to use it. In this example to I will use vim and Ubuntu.

  1. Select Configuration under the options menu in Midnight Commander.
  2. Deselect use internal edit and use internal view.
  3. Save your changes
  4. At the command line run $sudo update-alternatives --config editor
  5. Select Vim from list
  6. Add the following lines to your .bashrc
    • EDITOR=/usr/bin/vim
    • export EDITOR=/usr/bin/vim

Now when you select edit or view in MC Vim should start.

Last Updated on Friday, 21 January 2011 09:11