me, 2.0: jose nazario
beauty and the street

$ cvs -d SERVER co src/usr.bin/mgand then apply this patch to build the code. i compiled it with a simple brute force gcc invocation:
$ gcc -O2 -Wall -DDO_METAKEY -DPREFIXREGION -DXKEYS -DFKEYS -DREGEX \
-lcurses -o mg *.c
you're now left with an "mg" binary. install it in /usr/bin
and install the manpage. the key combos are mostly emacs, but you don't
have any of the plugins, or bloat, of emacs. not a bad compromise.
Index: fileio.c
===================================================================
RCS file: /cvs/src/usr.bin/mg/fileio.c,v
retrieving revision 1.49
diff -u -r1.49 fileio.c
--- fileio.c 3 Apr 2005 02:09:28 -0000 1.49
+++ fileio.c 25 Apr 2005 16:00:07 -0000
@@ -243,6 +243,7 @@
{
static char fnb[MAXPATHLEN];
const char *cp;
+#define LOGIN_NAME_MAX MAXLOGNAME
char user[LOGIN_NAME_MAX + 1], path[MAXPATHLEN];
int len;
Index: main.c
===================================================================
RCS file: /cvs/src/usr.bin/mg/main.c,v
retrieving revision 1.38
diff -u -r1.38 main.c
--- main.c 3 Apr 2005 02:09:28 -0000 1.38
+++ main.c 25 Apr 2005 16:00:07 -0000
@@ -97,10 +97,10 @@
for (nfiles = 0, i = 0; i < argc; i++) {
if (argv[i][0] == '+' && strlen(argv[i]) >= 2) {
int lval;
- const char *errstr;
+ char *errstr;
- lval = strtonum(&argv[i][1], INT_MIN, INT_MAX, &errstr);
- if (argv[i][1] == '\0' || errstr != NULL)
+ lval = (int)strtol(&argv[i][1], &errstr, 10);
+ if (argv[i][1] == '\0' || *errstr != NULL)
goto notnum;
startrow = lval;
} else {
Index: undo.c
===================================================================
RCS file: /cvs/src/usr.bin/mg/undo.c,v
retrieving revision 1.25
diff -u -r1.25 undo.c
--- undo.c 3 Apr 2005 02:09:28 -0000 1.25
+++ undo.c 25 Apr 2005 16:00:10 -0000
@@ -157,6 +157,7 @@
{
struct undo_rec *rec;
+#define LIST_END(head) NULL
rec = LIST_END(&curwp->w_undo);
if (rec != NULL) {
undo_free_num--;
next Tuesday, Apr 26, 2005 @ 07:55am | previous Sunday, Apr 24, 2005 @ 12:38pm | archives
| Last modified: Monday, Apr 25, 2005 @ 11:01am |
copyright © 2002-2005 jose nazario, all rights reserved.