[Top][All Lists]

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

Re: [Gnu-arch-users] missing feature: text file handling

From: Aaron Bentley
Subject: Re: [Gnu-arch-users] missing feature: text file handling
Date: Fri, 08 Oct 2004 07:29:03 -0400
User-agent: Mozilla Thunderbird 0.8 (X11/20040918)

John Meinel wrote:

Well, I ran into a problem. precommit doesn't happen soon enough. I can change the file permissions, and they are change in the filesystem, but the changeset has already been committed.

Oh, cute.  Yeah, I can confirm this behaviour:

changeset_path = arch_prepare_commit_changeset (&changelog_loc, chatter_fd, &cooked_log, tree_root, raw_log, base_arch, arch, base_revision, revision, prev_revision, file_list, escape_classes);

  invariant (!!prev_level || !!base_revision);

/* Check the error return code for the "precommit" hook and exit if non-zero.
error = arch_run_hook ("precommit", "ARCH_ARCHIVE", arch->name, "ARCH_REVISION", revision, "ARCH_TREE_ROOT", tree_root, 0) ;

Does this behaviour make sense to people? True, it provides a chance to edit the changeset, but you'd think people would rather have a chance to edit the tree. I guess we could also add a pre-precommit hook.

I also have to remember, that in a hardlinked tree, you can't change the mode of a file since it is still linked.

But if it's already hardlinked, it's already committed. So its permissions are probably right.

What is the correct way to break a hard link? Copy the file, and then move it over the old one?

That's right.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]