git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gerhard Wiesinger <lists@wiesinger.com>
To: Andreas Ericsson <ae@op5.se>
Cc: git@vger.kernel.org
Subject: Re: Metadata and checkin file date
Date: Tue, 27 Apr 2010 21:38:26 +0200 (CEST)	[thread overview]
Message-ID: <alpine.LFD.2.00.1004272111540.5630@bbs.intern> (raw)
In-Reply-To: <4BD6ACEF.1040909@op5.se>

On Tue, 27 Apr 2010, Andreas Ericsson wrote:

> On 04/27/2010 07:23 AM, Gerhard Wiesinger wrote:
>> Hello,
>>
>> I'm new to git and I'm looking for the following features:
>> 1.) Metadata for
>> a.) directory versioning (e.g. add/rm, mv)
>
> If you're talking about empty directories, that feature doesn't
> exist and I can't imagine why you'd want it to. If you'd care to
> explain why you want it, I'm sure we can find a different way of
> achieving your goal.

Git focuses on content but I think git should also focus on 
metadata. For example restructuring source code moves (git mv 
file1.c file2.c, git mv dir1 dir2) should be documented also in the 
repository like e.g. subversion and commercial SCM like clearcase do. 
Otherwise we are on "CVS" level.

Empty directories is a special case and sometimes you need just versioned 
empty directies.

>> b.) rights (basic: chmod, chow, chgrp, extended: extended attributes
>> like ACLs and selinux), necessary for versioning e.g. /etc
>
> Sounds like you want a backup-program. Some projects have been
> aimed towards this goal already. I'm sure google can provide
> more information. AFAIR, most of them work with two hook-scripts
> that update a regular file with the meta-data of all tracked
> files. This makes committing and checking out slower than it
> would otherwise be, but since it's doing more I suppose that's
> to be expected.
>
> Adding it to core git would mean re-designing git's basic data
> model, which is obviously not something we're about to do on
> a whim.

No, I'm NOT looking for a backup program. Every admin has the problem of 
versioning config files (for example /etc). Versioning of config files 
makes sense because one can track the changes and e.g. correlate to 
problems. A backup program doesn't have features like history, committer 
and comments on file changes. Therefore git would be a perfect tool also for 
versioning configuration. (Software development doesn't end with the build 
but typically also has deployment&configuration issues).

And when you think about a destroyed machine where you want to 
get your versioned configuration you also want to get the right 
permissions therefore. Otherwise you have for sure a security leak or a 
non working machine.

You can also think on machines where the same config should be used and 
tracked.

>> 2.) Original file dates (checkin date) on clone and pull (and not
>> checkout date)
>>
>
> I expect the solutions that work for 1b will also have this
> "feature", or that it will be easy to patch for it. For a
> source code management system though, this is a very bad
> idea indeed since it messes with the fundamental rules of
> building; A changed file must be rebuilt.
>
> Seeing as this would also require a major change in git's
> data model, this is another of those changes that I doubt
> will be supported in the git core in the foreseeable future.

I agree that a changed file must be rebuilt but in the normal "forward" 
cases that's also guaranteed with commit dates as they are "later". But 
when you get an old version you can't assume anything (e.g. dependencies 
have completly changed, even file structure) and therefore only a clean 
build (e.g. make clean) is IHMO valid.

I think git already has the commit date for the revision the user wants. 
Therefore only a call to "set_date_and_time" is necessary when a file 
is touched (e.g. by switch --use-commit-timestamps, environment variable 
or by config item). Therefor this should IHMO be easy to implement without 
any metadata changes.

Thnx.

Ciao,
Gerhard

  reply	other threads:[~2010-04-27 19:39 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-27  5:23 Metadata and checkin file date Gerhard Wiesinger
2010-04-27  9:22 ` Andreas Ericsson
2010-04-27 19:38   ` Gerhard Wiesinger [this message]
2010-04-27 19:47     ` Andreas Ericsson
2010-04-27 20:00       ` Gerhard Wiesinger
2010-04-27 21:25         ` Jakub Narebski
2010-04-27 21:18       ` Jakub Narebski
2010-04-27  9:35 ` Jakub Narebski
2010-04-27 19:41   ` Gerhard Wiesinger
2010-04-27 20:55     ` Jakub Narebski

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=alpine.LFD.2.00.1004272111540.5630@bbs.intern \
    --to=lists@wiesinger.com \
    --cc=ae@op5.se \
    --cc=git@vger.kernel.org \
    /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).