Live data from Hacker News

Mg: an Emacs-like editor in 160 kb

homepage.boetes.org

11–20 of 84 posts

Re: Mg: an Emacs-like editor in 160 kb

#12
post #11
post #10

I use emacs for most of my daily development, but always rely on nano or vi in the terminal due to emacs startup time. I'm going to give mg a shot this week!

You could also run Emacs as a server.

I've actually looked into this, but it seemed like far too much overhead to simply open, edit and save a file; especially remotely.

Re: Mg: an Emacs-like editor in 160 kb

#13
post #12
post #11

Earlier quoted context omitted.

You could also run Emacs as a server.

I've actually looked into this, but it seemed like far too much overhead to simply open, edit and save a file; especially remotely.

Remotely, sure (though I usually use joe for that), but for local edits, I start emacs --daemon as part of my regular login procedure (along with creating multiple terminal windows) and thereafter use emacsclient (aliased to 'e') for almost all file editing.

Only annoying thing is the way it retains buffers for modified files when you exit, even if you choose not to save them.

emacs -q (or faster, -Q) could be used in a pinch, but I find default emacs almost unusable.

Re: Mg: an Emacs-like editor in 160 kb

#15
post #12
post #11

Earlier quoted context omitted.

You could also run Emacs as a server.

I've actually looked into this, but it seemed like far too much overhead to simply open, edit and save a file; especially remotely.

You can edit remote files directly in Emacs or simply use sshfs.

Re: Mg: an Emacs-like editor in 160 kb

#17
post #9

As an Emacs guy, I really like mg(1). The one missing feature is Unicode support.

Patches welcome. The first step would be iconv in OpenBSD base (there are existing BSD-licensed implementations to start from). Then have mg make use of it. http://marc.info/?l=openbsd-tech&m=134581162518146&w=2 (Edit: Or try adding a pure UTF-8 mode)

Re: Mg: an Emacs-like editor in 160 kb

#18
For some curious reason all my browser right-click download efforts on that webpage resulted in a wrong-sized corrupted file. Yet good old curl does the job just fine:

    curl -O http://homepage.boetes.org/software/mg/mg-20150316.tar.gz
And I can't remember when the last time i've had a program compile with just 'make' and no messing about. It's quite impressive. Thank you!

Re: Mg: an Emacs-like editor in 160 kb

#19
> Since it is written completely in C, there is currently _no language in which extensions can be written_; however, keys can be rebound and certain parameters can be changed in startup files.

mg seems almost, but not quite, entirely unlike emacs.

the thing that makes emacs emacs is not the keybindings or the so-called "modeless" editing (which is a misinterpretation by vim folks, emacs is way more modeful than vim), but the built-in scriptability / extensibility.

Re: Mg: an Emacs-like editor in 160 kb

#20

> Since it is written completely in C, there is currently _no language in which extensions can be written_; however, keys can be rebound and certain parameters can be changed in startup files. mg seems almost, but not quite, entirely unlike emacs. the thing that makes emacs emacs is not the keybindings or the so-called "modeless" editing (which is a misinterpretation by vim folks, emacs is way more modeful than vim),…

Not when I'm on some tiny VM or computer and want something nicer than Nano that has something remotely close to Emacs keybindings. Then it's the keybindings, not the scriptability. I just want a reasonable editor.
Post reply on HN