Skip to Content.
Sympa Menu

sm-discuss - Re: [SM-Discuss] Auto-generated HISTORY from `git commit` (was Re: [SM-Commit] GIT changes to master grimoire by George Sherwood (7041bfdaf256227abdacc42113e14388785aae43))

sm-discuss AT lists.ibiblio.org

Subject: Public SourceMage Discussion List

List archive

Chronological Thread  
  • From: flux <flux AT sourcemage.org>
  • To: sm-discuss AT lists.ibiblio.org
  • Subject: Re: [SM-Discuss] Auto-generated HISTORY from `git commit` (was Re: [SM-Commit] GIT changes to master grimoire by George Sherwood (7041bfdaf256227abdacc42113e14388785aae43))
  • Date: Thu, 11 Jun 2009 18:19:32 -0400

George Sherwood (pilot AT beernabeer.com) wrote [09.06.11 12:57]:
> For me almost the opposite would be easier. I wish it was possible to
> generate my commit message from the quill generated HISTORY entry.
> Almost all of my updates are doing using quill. I just change the
> wording a little bit, but it is nice to have the version already
> there. No entry mistakes.
>
> George

Even if we don't do this project-wide, it's entirely possible to do this
in your local working directory via git hooks (I believe). Try
implementing a script that runs sed/grep or something and see if it fits
well for you. I'm not sure everyone would want this, but I think it's a
good idea to develop the solution first and test it out so everyone can
see it and know what it is. Personally, I like the idea, but I won't be
implementing the same behavior in my clone since I don't deal with
HISTORY often enough (I'm usually doing commits against cauldron far
more often, and I simply got rid of the HISTORY file there).

With regards to the reverse (having HISTORY created from commit
messages), it could also be implemented from commit messages, though we
would need some kind of commit parsing if the HISTORY file itself were
also to be committed (relatively easy, just check if the commit is for a
file named HISTORY and don't do the processing if it is). However, if
your commit messages are well-formatted, why use HISTORY at all? Why not
just rely on the git commit messages alone to do the job? The relevant
info could just be extracted out when generating releases to create
changelogs, and otherwise the hisotry will always be there as long as
the repo doesn't eat itself (which I really doubt happening, since git
has proven to be quite solid for some time). Also, if the HISTORY files
only exist in the repo itself anyway (aside from the generated tarballs,
which we could generate backups of the repo to achieve the same effect),
if the repo eats itself those files are gone anyway, reducing their
effectiveness.

git log --pretty=online ftw? :)

--
Justin "flux_control" Boffemmyer
Cauldron wizard and general mage
Source Mage GNU/Linux
http://www.sourcemage.org

Attachment: pgpBoPvA7Ifos.pgp
Description: PGP signature




Archive powered by MHonArc 2.6.24.

Top of Page