tech-repository archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Git and ident of binaries

On Wed, Jan 13, 2010 at 09:07:27AM +0900, Curt Sampson wrote:
> [Drop current-users@ in replies, please.]
> On 2010-01-12 23:56 +0000 (Tue), Thomas Adam wrote:
> > You distribute the hook as part of the repository and use a README file --
> > no, I am not being flippant, that's how this sort of thing gets managed in
> > other projects.
> How often is this subject to human failure, where someone forgets to set
> up the hook and ends up committing changes with the old id?

They wouldn't commit the "old" ID, if you used the mechanism from
gitattributes.  Adding in both is redundant, surely?  I mean, one of them no
longer maps to any of the history now stored in the repository.

You appreciate the reasons why these scripts aren't cloned and then made
executable; security.  So, human error aside, what you would have to do is
instead have a script on the post-receive-hook end in the bare repository
(the "centralised" repository people push back to, to deny a push if it
doesn't conform to some "standard".

This sort of thing does work, BTW, but it creates a much higher overhead on
the person trying to commit as they then have to ammend their commit
messages potentially (the mechanism for doing this depends on how they
formed up the set of commits on a branch in the first place --- but that's
for another discussion).

So yes, human error, etc., etc., I am not sure how best to solve this, but
if you've got people with *commit* access not already having their
repository in a state which conforms to some standard, then you've got
larger communication problems, quite frankly.

> > "man gitattributes" -- Git has expansion for $Id$ placeholders....
> And for arbitrary filters as well, which means we can just commit a
> filter that does the appropriate $NetBSD$ munging if we don't like
> touching $Id$ (which I think we don't, since sometimes we want the $Id$
> of something that was imported).
> So, problem solved, if we need to maintain this feature.

What would you use this for?

-- Thomas Adam

"It was the cruelest game I've ever played and it's played inside my head."
-- "Hush The Warmth", Gorky's Zygotic Mynci.

Home | Main Index | Thread Index | Old Index