git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <junkio@cox.net>
To: Jeff King <peff@peff.net>
Cc: git@vger.kernel.org, Tom Prince <tom.prince@ualberta.net>
Subject: Re: [PATCH] contrib/vim: add syntax highlighting file for commits
Date: Tue, 12 Sep 2006 23:12:08 -0700	[thread overview]
Message-ID: <7vy7so9txj.fsf@assigned-by-dhcp.cox.net> (raw)
In-Reply-To: <20060912023256.GA6596@coredump.intra.peff.net> (Jeff King's message of "Mon, 11 Sep 2006 22:32:57 -0400")

Jeff King <peff@peff.net> writes:

> On Mon, Sep 11, 2006 at 08:08:13PM -0600, Tom Prince wrote:
>
>> > +  1. Copy commit-syntax.vim to vim's syntax directory:
>> > +     $ cp commit-syntax.vim $HOME/.vim/syntax/gitcommit.vim
>> It would be more obvious if you could do cp gitcomit.vim $HOME/.vim/syntax/
>
> It would be with only one file, but you could just as easily have a
> .vim/ftplugin/gitcommit.vim file (I think there are others, too). If you
> want to give it the "proper" name, it should probably be
> syntax/gitcommit.vim.

I am not a vim user, but my reading of Tom's comment is that he
thinks it would have been nicer if the file the patch adds were
named gitcommit.vim, not commit-syntax.vim.  As you seem to
agree that the preferred name for this file when deployed is
gitcommit.vim, how about something like this on top of your
patch perhaps?


diff --git a/contrib/vim/README b/contrib/vim/README
index bad0a05..f574cc8 100644
--- a/contrib/vim/README
+++ b/contrib/vim/README
@@ -1,6 +1,6 @@
 To syntax highlight git's commit messages, you need to:
-  1. Copy commit-syntax.vim to vim's syntax directory:
-     $ cp commit-syntax.vim $HOME/.vim/syntax/gitcommit.vim
+  1. Copy gitcommit.vim to vim's syntax directory:
+     $ cp gitcommit.vim $HOME/.vim/syntax/
   2. Auto-detect the editing of git commit files:
      $ cat >>$HOME/.vimrc <<'EOF'
      autocmd BufNewFile,BufRead COMMIT_EDITMSG set filetype=gitcommit
diff --git a/contrib/vim/commit-syntax.vim b/contrib/vim/gitcommit.vim
similarity index 100%
rename from contrib/vim/commit-syntax.vim
rename to contrib/vim/gitcommit.vim

  reply	other threads:[~2006-09-13  6:12 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-11 23:22 [PATCH] contrib/vim: add syntax highlighting file for commits Jeff King
2006-09-12  2:08 ` Tom Prince
2006-09-12  2:32   ` Jeff King
2006-09-13  6:12     ` Junio C Hamano [this message]
2006-09-13  6:25       ` Jeff King
2006-09-13  6:46         ` Tom Prince

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=7vy7so9txj.fsf@assigned-by-dhcp.cox.net \
    --to=junkio@cox.net \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    --cc=tom.prince@ualberta.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).