I'm looking for modeless TUI (console) text editor with the following features

  1. (required) Should run on Linux. Support of other UNIX-likes, Mac and Windows is nice to have but optional.
  2. (required) Searching and replacing text matching a regular expression.
    • Support of short character class names (\w, \s, etc.) is a must.
    • Support of end or start of line ($, ^) is a must
    • Ability to use regular expression groups in replacement text is a plus. But not strictly necessary.
  3. (required) Recording multiple macros and binding them to keys
  4. (very desirable, but can live without it) Syntax highlighting for: C/C++, bash, python, rust, go, Makefiles
  5. (nice to have but not necessary) Ability to open multiple files and switching between them.

List of editors I have already tried and found them lacking

  • GNU nano. Quite like it. But it can record only one macro and can't persist it between restarts.
  • micro. Same as nano.
  • VIM Just can't stand switching modes. I tried really hard. For a long time. Followed multiple tutorials to make sure I'm not using it wrong. Just don't like it.
  • Emacs could probably also fit the bill but it is too slow to start.
  • JOE has no support for proper regular expressions. What its man page calls 'Regular expressions' are not enough for me
  • mcedit (the stock editor of Midnight Commander) comes very close. It supports both proper regular expressions and macro recording. But parameters of some commands (including replacement) are not stored in recorded macro. When you run a macro containing replacement command it just opens 'Replace' dialog for you instead of doing the same replacement again
  • ox (this one https://github.com/curlpipe/ox) is promising but half-baked. It has regexp and macros support but macros have to me written manually in a special language. They can not be recorded.
  • Tilde (https://os.ghalkes.nl/tilde/) supports regex but has no macros.
  • mle (https://github.com/adsr/mle) like ox mle has regexp support but macro can not be recorded and have to be written by hand in a special language
  • multitextor (https://github.com/vikonix/multitextor) resembles mcedit. Has macro recording but has only one macro, does not save it on exit and just like mcedit does not save operation parameters in macros
  • Since mcedit and multiplexor comes close and are both actively maintained as Free software, I would recommend to file a wishlist request at the bugtracker of both those projects, and see if the authors find your needs interesting to implement.
    – Jonas
    May 17 at 18:53


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.