small yet mighty GNU Emacs style editor
Kevin Bloom 7e3d573824 might have fixed another bug with memory on NetBSD | 21 часов назад | |
---|---|---|
docs | 1 месяц назад | |
scripts | 4 дней назад | |
.gitignore | 1 год назад | |
AE_LICENSE | 1 год назад | |
BSD_LICENSE | 9 месяцев назад | |
GNUmakefile | 4 дней назад | |
LICENSE | 9 месяцев назад | |
NEWS | 2 дней назад | |
README.md | 1 месяц назад | |
ait.1 | 4 дней назад | |
buffer.c | 1 месяц назад | |
command.c | 21 часов назад | |
complete.c | 2 месяцев назад | |
display.c | недель назад: 2 | |
gap.c | 1 месяц назад | |
header.h | 4 дней назад | |
hilite.c | недель назад: 3 | |
key.c | 5 дней назад | |
main.c | 4 дней назад | |
makefile | 5 дней назад | |
replace-share.awk | 5 дней назад | |
replace.c | 5 дней назад | |
search.c | недель назад: 3 | |
shell.c | 4 дней назад | |
syntax.h | 2 дней назад | |
termbox.h | 9 месяцев назад | |
unicode.h | 9 месяцев назад | |
util.c | 2 дней назад | |
util.h | 1 месяц назад | |
window.c | 1 месяц назад |
ait is inspired by GNU Emacs, acme, mle, microEMACS, mg, and vi/vim/neovim. Based on Atto. Started as a fork of Atto but was then ported to Termbox2 to become what it is now. ait can be compiled with no dependencies other than libc. It should work on all unix-like systems although at this point it only works on GNU/Linux (glibc & musl), macOS, FreeBSD, and NetBSD.
scripts/spell
command on a word, it would
replace the word.The purpose of this editor is to be similar enough to Emacs but
without the extra stuff. It focuses on using the existing system to do
things, and having smaller footprint without lacking in important
editor features. To do this, most of the keybindings are the vanilla
Emacs bindings with a few exceptions, having similar buffer and cursor
controls, and having a familiar look. Instead of rewriting everything
in C, ait allows you to use shell commands as an pseudo-extension
language. See scripts/
for more information.
The codebase comes from 2 other authors, most of which was written back in the 90s. That being said, some of the code is clearly outdated but since it works, I have no desire to rewrite it. There is also no reason for me to support things that I don't actually use or things that can easily be done using an existing function. For example, multiple cursors is really great but a complicated feature to add when most situations can be solved using keyboard macros.
ait stands for Atto In Termbox or Atto Implemented in Termbox. Also, an
ait is a small island usually found in
rivers. I thought about calling it simply At but there is already a program
called at
1 2
3
4 5. My wife
also came up with the name of aint, standing for Atto IN Termbox and having the
catch phrase of "because it ain't your editor."
From Atto's README: "Atto is based on the public domain code of Anthony Howe's editor (commonly known as Anthony's Editor or AE, [2]). Rather than representing a file as a linked list of lines, the AE Editor uses the concept of a Buffer-Gap [4,5,6]. A Buffer-Gap editor stores the file in a single piece of contiguous memory with some extra unused space known as the buffer gap. On character insertion and deletion the gap is first moved to the current point. A character deletion then extends the gap by moving the gap pointer back by 1 OR the gap is reduced by 1 when a character is inserted. The Buffer-Gap technique is elegant and significantly reduces the amount of code required to load a file, modify it and redraw the display. The proof of this is seen when you consider that Atto supports almost the same command set that Pico supports, but Pico requires almost 17 times the amount of code."
ait comes from Atto so the derivation is trival. I just ported it to termbox and started hacking in my own changes for fun.
See issues.
ait code is released under the BSD 3-Clause License. Atto code is released to the public domain. Anthony's Editor code claims to be public domain but contains a questionable (see AE_LICENSE) license that isn't actually public domain. See the LICENSE file for the offical statements.
Hugh Barney for writing Atto.
Anthony Howe for writing Anthony's Editor.
GNU Emacs for keybindings, power, and inspritation.
Plan 9's acme for inspiration.
mle for inspiration and guidance.
Termbox2 for being nice.
Adam Saponara for making the previous 2.