An Emacs-like text editor written in Ruby
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
exe Use match? instead of =~ Feb 7, 2019
lib Use popen3 instead of popen2e Feb 20, 2019
logo Add a logo. Feb 21, 2019
test Use +"" instead of Feb 12, 2019
.editorconfig Fixes for Windows Jan 10, 2019
.travis.yml Remove bundle-audit Jan 9, 2019 Add 0.3.2 to CHANGES Feb 8, 2019
Gemfile text_bringer/TextBringer -> textbringer/Textbringer. Jan 5, 2017
appveyor.yml Drop Ruby 2.3 support Feb 7, 2019
screenshot.png Add screenshot. Aug 22, 2017
textbringer.gemspec Update required_ruby_version to 2.4 Feb 8, 2019


Gem Version Build Status Build status codecov

Textbringer is a member of a demon race that takes on the form of an Emacs-like text editor.





Textbringer is beta software, and you may lose your text. Unsaved buffers will be dumped in ~/.textbringer/buffer_dump on crash.

APIs are undocumented and unstable. There is no compatibility even in the same minor versions.


$ gem install textbringer

You need ncursesw to use multibyte characters. Install ncursesw before installing curses.gem, on which textbringer depends.

$ sudo apt-get install libncursesw5-dev
$ gem install curses


$ textbringer

You can quit the editor by Ctrl-x Ctrl-c.

Many commands and key bindings are similar to Emacs.

Type F1 b or Alt+x describe_bindings RET to see key bindings.


Meta key

You need the following configuration of terminal emulators to use meta key.


Add the following line to ~/.Xresources.

XTerm*metaSendsEscape: true


Add the following lines to ~/.mlterm/main.

mod_meta_key = alt
mod_meta_mode = esc

East asian ambiguous width

Add the following line to ~/.textbringer.rb to treat ambiguous characters as fullwidth.

CONFIG[:east_asian_ambiguous_width] = 2

You also need a LD_PRELOAD hack or a modified locale charmap because ncursesw uses wcwidth(3).

xterm, mlterm and screen have their own configuration options.


Add the following lines to ~/.Xresources.

xterm*utf8: 1
xterm*locale: true
xterm*cjkWidth: true


Add the following line to ~/.mlterm/main.

col_size_of_width_a = 2


Add the following line to ~/.screenrc.

cjkwidth on


After checking out the repo, run bundle install to install dependencies. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the .gem file to


Bug reports and pull requests are welcome on GitHub at


The gem is available as open source under the terms of the MIT License.


Logo made with DesignEvo.