All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Eric Wong <normalperson@yhbt.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] builtin-config: add --exec-editor for use in scripts
Date: Sun, 01 Feb 2009 19:04:10 -0800	[thread overview]
Message-ID: <7v4ozdo7yt.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: 20090201025349.GA22160@dcvr.yhbt.net

Eric Wong <normalperson@yhbt.net> writes:

> This exposes the launch_editor() library function for use by
> various scripting languages.  This allows the ensure consistent
> handling of GIT_EDITOR/VISUAL/EDITOR environment variables as
> well as the handling of special characters such as spaces in the
> various environment variables.
>
> Signed-off-by: Eric Wong <normalperson@yhbt.net>
> ---
>
>  I'm not sure if git-config is the best place to stick it.  I plan to
>  start using this in git-svn but I don't want to implement Git::Editor
>  in Perl and have to keep track of editor.c.  Of course this also makes
>  the logic/rules used in libgit usable to any other scripting language
>  capable of launching other programs.

I agree that git-config is probably a wrong place.  A separate command
"git editor" (or "git user-preference --editor", if you extend it to pager
and others) perhaps?

I also agree that something like this would make scripting Porcelains a
much pleasant experience.

  reply	other threads:[~2009-02-02  3:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-01  2:53 [PATCH] builtin-config: add --exec-editor for use in scripts Eric Wong
2009-02-02  3:04 ` Junio C Hamano [this message]
2009-02-02  9:56   ` Jakub Narebski
2009-02-03  4:55     ` Eric Wong
2009-02-03  6:30       ` Junio C Hamano

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=7v4ozdo7yt.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=normalperson@yhbt.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.