Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2007-11-02 18:33:08 +0300
committerJunio C Hamano <gitster@pobox.com>2007-11-23 04:05:02 +0300
commit943316e96ca2dad67086af2f945e42467a27ddd6 (patch)
tree50b5a90729d6f0c85bb6e02938d1426aafeee983 /builtin-tag.c
parentd63c2fd192271ea2d85c81edfad90aa42fec26ee (diff)
Export launch_editor() and make it accept ':' as a no-op editor.
Signed-off-by: Kristian Høgsberg <krh@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-tag.c')
-rw-r--r--builtin-tag.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/builtin-tag.c b/builtin-tag.c
index cbb0f04e85..88a5449e67 100644
--- a/builtin-tag.c
+++ b/builtin-tag.c
@@ -17,7 +17,7 @@ static const char builtin_tag_usage[] =
static char signingkey[1000];
-static void launch_editor(const char *path, struct strbuf *buffer)
+void launch_editor(const char *path, struct strbuf *buffer)
{
const char *editor, *terminal;
struct child_process child;
@@ -42,6 +42,9 @@ static void launch_editor(const char *path, struct strbuf *buffer)
if (!editor)
editor = "vi";
+ if (!strcmp(editor, ":"))
+ return;
+
memset(&child, 0, sizeof(child));
child.argv = args;
args[0] = editor;