summaryrefslogtreecommitdiff
path: root/usr.bin/mg
AgeCommit message (Collapse)Author
2011-07-15When killing lines using ^U <n> ^K, count the characters exactly (forTheo de Raadt
both forwards and backwards cases, though the forward case is better tested. This is required because the actual character deleter function (ldelete) requires an exact count. If it runs short, it will not put the deletion into the kill buffer. This is complicated by how mg internals consider newline's as counted characters even though they do not occur in the buffers... and then there is the no newline at EOF fiasco....
2011-07-08hackathons are good to this fileDamien Miller
2011-02-02Put correct path for tutorial into man page. oops.lum
2011-02-02Move mg(1) tutorial file into a release, instead of languishing in src.lum
ok nick@ schwarze@ miod@ kjell@
2011-01-23Wrap basename,dirname with xbasename, xdirname funtions,Kjell Wooding
which have fewer special cases, and use the strlcpy/strlcat src/dst/buffer len semantic. More portable to boot. Discussion and feedback from Henri Kemppainen
2011-01-21It volates style(9), but in mg, #include"def.h" goes first. 'twas the way it ↵Kjell Wooding
was built. no binary change here. confirmed by lum@, tested by Henri Kemppainen
2011-01-21Change len+memcmp check to a strncmp for prefix testing onKjell Wooding
filename completion. Avoids a recurring portability headache. ok lum@ "concerns assuaged to the soothing sounds of Martin Denny blambert@" (I worry about that guy...)
2011-01-19patch from Henri Kemppainen:Kjell Wooding
clean up undo boundaries for functions in random.c This catches an error, where twiddling in an empty file could disable undo boundaries for the rest of the session. proper undo boundaries around newline() will have to wait until proper reference counting is done... Thanks!
2011-01-18new sentence, new line;Jason McIntyre
2011-01-18Add missing prototypes and move dired.c to "extensions" in Makefile.lum
ok kjell@
2011-01-18augbname immediately does a basename. No need to do it in theKjell Wooding
caller, too. ok lum@
2011-01-18Obvious error on my part.Kjell Wooding
test len against INT_MAX, not SIZE_MAX. 'looks good' jasper@
2011-01-18Add join-line, bound to M-^Kjell Wooding
Join the current line to the previous. original diff by Henri Kemppainen. minor mod to add undo boundaries. Thanks!
2011-01-17Add back-to-indentation. (M-m)Kjell Wooding
Move the dot to the first non-whitespace character on the current line. from Henri Kemppainen . ok theo
2010-10-07use an upper case "C" in "Control" for consistency; use the sameIgor Sobrado
capitalization for keys in Control and Meta for both key bindings and descriptions. ok kjell@
2010-08-03that had to be addedHenning Brauer
2010-06-30you keep saying LIST_END. I do not think it means what you think itOwain Ainsworth
means. If we hit an OOM condition, mg started to try and dump the older undo buffer entries in order to be able to continue. OTOH, it was grabbing this entry with LIST_END, which like all *_END() list macros evaluates to NULL. Do what we actually want and switch that list to a TAILQ and use TAILQ_LAST to grab the last entry. Wrote this a loooooong time ago after a mail from Matthew Dempsky on bugs@. ok kjell@, beck@ also looked at this months ago and thought it was alright.
2010-06-26From the Loganaden Velvindron:Kjell Wooding
Make dired more sane (and emacslike): * Position cursor at first filename after .. * Don't reposition cursor on reopening * Check for permission before attempting to open directory I took forever to get this in. Thanks, Logan for being patient!
2010-06-24this just had to be here...Jasper Lievisse Adriaanse
2010-03-26dispense with some wacky escape sequences;Jason McIntyre
2010-03-03it's true!Jasper Lievisse Adriaanse
2010-01-24- revert previous; nitems() shouldn't be used in userland (yet).Jasper Lievisse Adriaanse
ok kjell@
2010-01-24use nitems here, no real changeTed Unangst
2010-01-01when asked for the benefit of pre-selecting pkgs in the installer;Ingo Schwarze
ok kettenis
2009-11-24Another one.Owain Ainsworth
"yup" henning@
2009-11-24More words of wisdom.Owain Ainsworth
ok henning@ dms@
2009-11-12fix memory leak found by parfait; ok jsg@Todd C. Miller
2009-10-28style(9) has all these fascist rules...Claudio Jeker
2009-08-12i am sorry to commit to userland from a kernel hackathonHenning Brauer
2009-07-07..couldn't resist..Jasper Lievisse Adriaanse
2009-06-23Escape ) to make "C-x )" spaced correctly in key list.Nicholas Marriott
"if it formats correctly, go for it" jmc@
2009-06-05swap function order to bring into scopeTheo de Raadt
2009-06-05emacs handles the undo of a region kill (C-w) differently than a line killKjell Wooding
(C-k) with respect to cursor position. The former leaves the cursor at the end, the latter at the beginning of the region. emacs is wacky. Make mg undo do the same. ok deraadt
2009-06-05the theJason McIntyre
2009-06-04If a buffer is created with a name that starts and ends with an askeriskKjell Wooding
(e.g. *scratch*, *Completions*, *grep*) it is considered throwaway; i.e. the user will NOT be prompted to save changes when the buffer is killed.
2009-06-04Add the notion of an "ephemeral" popup, so we can flag a windowKjell Wooding
for destruction at a later date. (in the process, add a window flag field) This fixes an issue noted by maja: namely, the *completion* window that pops up when you try to complete a filename on buffer load would destroy any second window that you happened to have open. ok maja@
2009-06-04Fix problem where line numbers get out of sync on a region-kill (C-w).Kjell Wooding
Noticed and ok matthieu@
2009-06-04Rename w_flag to w_rflag. This is not a general purposeKjell Wooding
flag: it is for redisplay options only. I need an additional all-purpose flag, so renaming removes the desire to wrongly overload the existing one. Turdshine. No functional chage.
2009-06-03Match comment to reality, whitespaceKjell Wooding
2009-06-02we were erroneously setting fill-column, even when the inputKjell Wooding
to set-fill-column was garbage. (common, since they keystroke is so close to find-file). Fix!
2009-06-02Fix up some comments to match realityKjell Wooding
2009-06-02Fix the long-standing crash when >NXNAME characters were insertedKjell Wooding
into minibuffer. Found and fixed by Martynas. Cleaned up a bit so that error messages display properly in the status line. Fixes Debian bug #414846
2009-04-26make djm less disappointedStuart Henderson
2009-04-26I am disappointed that the commit rate to this file is has slowed.Damien Miller
2008-12-23time to add a new one.Claudio Jeker
2008-12-17change the name displayed by the c-mode on the mode line to "c",Igor Sobrado
as other modes do, for consistency and to save a few chars. written with help from kjell@ ok kjell@
2008-12-17sort CFLAGS, SRCS and the list of compile-time options; while here,Igor Sobrado
add some missing full stops. ok kjell@
2008-11-15update the readme a bit by deleting most of the irrelevant info, such as msdosTed Unangst
support and who to mail for 5" floppies... ok kjell
2008-11-06add a description for the recently added c-mode.Igor Sobrado
ok jmc@
2008-09-15Expose the undo commands as proper mg functions.Kjell Wooding
This should have no functional change on undo, but it does facilitate testing undo behavior.