nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] Ditch autoconf selection of pager?

2013-01-14 17:02:04


Ken Hornstein wrote:
not all terminals were capable of doing the cursor addressing needed
for any given screen-oriented editor.  so the user was given the ability
to configure two editors -- likely "ed" and "vi", though some folks may
have used emacs or "se" :-).  some programs had separate commands for
invoking the two.  (for instance, see ~e and ~v in the mailx man page.)

Ok, so I get in the mailx case there was ~e and ~v.  But how did other
programs know when to use VISUAL and when to use EDITOR?  I guess that's
the real confusing part to me; it was never clear to me how that decision
was made (all of the examples I ever found checked VISUAL then fell back
to EDITOR).

none of us knew. here's what "crontab" does for its -e mode.

#if defined(_PATH_VI)
# define EDITOR _PATH_VI
#else
# define EDITOR "/usr/ucb/vi"
#endif

...

        if ((!(editor = getenv("VISUAL")))
         && (!(editor = getenv("EDITOR")))
            ) {
                editor = EDITOR;
        }

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers
<Prev in Thread] Current Thread [Next in Thread>