Git development
 help / color / mirror / Atom feed
From: David Kastrup <dak@gnu.org>
To: Yann Dirson <ydirson@altern.org>
Cc: Junio C Hamano <gitster@pobox.com>, git@vger.kernel.org
Subject: Re: Interpreting EDITOR/VISUAL environment variables.
Date: Wed, 01 Aug 2007 21:30:57 +0200	[thread overview]
Message-ID: <85ir7zrr0u.fsf@lola.goethe.zz> (raw)
In-Reply-To: <20070801185042.GB30277@nan92-1-81-57-214-146.fbx.proxad.net> (Yann Dirson's message of "Wed\, 1 Aug 2007 20\:50\:42 +0200")

Yann Dirson <ydirson@altern.org> writes:

> On Wed, Aug 01, 2007 at 10:12:13AM -0700, Junio C Hamano wrote:
>> We recently normalized the script callers not to splice at all
>> (the scripts were hand-rolling "the VISUAL or EDITOR or vi" and
>> slightly differently).  It obviously has negative (i.e. setting
>> EDITOR to "emacsclient --alternate-editor vi" does not work) as
>> well as positive side (i.e. "/home/dak/My Programs/editor" would
>> work).
>
> And, indeed, --alternate-editor could be supplemented by another
> envvar to be able to work in our situation.

It is already.  But if git is pretty much alone in breaking a setup
that is working everywhere else, is having a workaround available
really a good excuse for not doing the right thing?

> Maybe the various emacsen vendors would be willing to integrate such
> a patch ?

Actually, it is a nuisance because nobody remembers this variable.  It
is called (looking in the Emacs manual, using the index to find
emacsclient, following a link after two pages to the invocation, going
down two pages again) ALTERNATE_EDITOR.  It does not even _mention_
Emacs or emacsclient in its name.  The "-a" option is easier to
remember.

So yes, emacsclient has an environment hook making it possible to work
around git's idiosyncratic behavior here.  But should it really be
necessary?

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

  reply	other threads:[~2007-08-01 19:32 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-01 13:36 Interpreting EDITOR/VISUAL environment variables David Kastrup
2007-08-01 17:12 ` Junio C Hamano
2007-08-01 18:50   ` Yann Dirson
2007-08-01 19:30     ` David Kastrup [this message]
2007-08-01 19:08   ` David Kastrup
2007-08-01 19:53     ` Junio C Hamano
2007-08-01 21:47       ` [PATCH] git-sh-setup.sh: make GIT_EDITOR/core.editor/VISUAL/EDITOR accept commands David Kastrup
2007-08-01 22:17         ` David Kastrup
2007-08-01 21:47           ` David Kastrup
2007-08-01 23:18           ` Junio C Hamano
2007-08-01 23:21             ` Junio C Hamano
2007-08-01 23:58               ` David Kastrup
2007-08-02  1:00                 ` Junio C Hamano
2007-08-01 23:55             ` David Kastrup
2007-08-02 10:10     ` Interpreting EDITOR/VISUAL environment variables Matthias Lederhofer
2007-08-02 10:31       ` David Kastrup

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=85ir7zrr0u.fsf@lola.goethe.zz \
    --to=dak@gnu.org \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=ydirson@altern.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox