Dear diary, on Fri, Jul 22, 2005 at 12:37:05PM CEST, I got a letter
where Catalin Marinas <[EMAIL PROTECTED]> told me that...
> > Cogito seems to use $GIT_DIR/commit-template for that purpose.
> > Can't users put that "vim:" hint there, and if StGIT does not
> > use a commit template, patch it to use the same file as Cogito
> > does?
>
> I would use a neutral commit template, only that it should have a
> neutral prefix as well for the lines to be removed (neither STG nor CG
> but GIT maybe). The $GIT_DIR/commit-template is fine as a file name.
This unfortunately isn't that simple, since this file substitutes only
the
CG:
-----------------------------------------------------------------------
CG: Lines beginning with the CG: prefix are removed automatically.
snippet of the file. The trouble is, Cogito autogenerates most of the
rest of it. Would the acceptable solution be that I would have
@[EMAIL PROTECTED] placeholders there, and any tool processing the
file would simply drop lines containing @ directives it does not
understand? (@@ is escaped @)
I have nothing against changing the prefix to GIT:.
Then, Cogito's default commit-template would look like
GIT:
-----------------------------------------------------------------------
GIT: Lines beginning with the GIT: prefix are removed automatically.
GIT:
GIT: Author: @AUTHOR_NAME@
GIT: Email: @AUTHOR_EMAIL@
GIT: Date: @AUTHOR_DATE@
GIT:@CG_SHOWFILES@@CG_NOMERGE@
GIT:@CG_SHOWFILES@@CG_NOMERGE@ By deleting lines beginning with GIT:F,
the associated file
GIT:@CG_SHOWFILES@@CG_NOMERGE@ will be removed from the commit list.
GIT:@CG_SHOWFILES@
GIT:@CG_SHOWFILES@ Modified files:
GIT:@[EMAIL PROTECTED] @FILELIST@
GIT:
-----------------------------------------------------------------------
GIT: vim: textwidth=75
(where CG_SHOWFILES is defined only when the list of the files is to be
shown and CG_NOMERGE only when there is no merge going on).
--
Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
If you want the holes in your knowledge showing up try teaching
someone. -- Alan Cox
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html