public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Pete Wyckoff <pw@padd•com>
To: Jonathan Nieder <jrnieder@gmail•com>
Cc: Junio C Hamano <gitster@pobox•com>,
	git@vger•kernel.org, Christian Couder <chriscool@tuxfamily•org>
Subject: Re: [PATCH] teach update-index --refresh about --data-unchanged
Date: Wed, 3 Nov 2010 18:02:43 -0400	[thread overview]
Message-ID: <20101103220243.GA6777@arf.padd.com> (raw)
In-Reply-To: <20101103183621.GA14019@burratino>

jrnieder@gmail•com wrote on Wed, 03 Nov 2010 13:36 -0500:
> On Wed, Nov 03, 2010 at 10:37:40AM -0700, Junio C Hamano wrote:
> > Pete Wyckoff <pw@padd•com> writes:
> 
> >> When a repository has been copied with rsync, or cloned using
> >> a volume manager, the index can be incorrect even though the
> >> data is unchanged.  This new flag tells update-index --refresh
> >> that it is not necessary to reread the data contents.
> >
> > I know our traditional attitude towards the plumbing commands have been
> > "give them long enough rope and let users hang themselves", but this
> > particular rope feels a bit too long for my taste.
> 
> Pete, I think you mentioned the possibility of a special-case tool for
> contrib/ that just updates the inode, device number, and ctime fields?
> That sounds a little less worrying to use, as plumbing.

Yes, I'd been discussing with Jonathan offlist that I too agree
this is a bit bizarre for general use.  Especially when thinking
about how to explain the new flag in the manpage, and how
interactions with other command-line options should work.

I wrote a short C program to use existing functions from cache.h
to read and write the index, updating the entries by hand.  Once
I figure out how to build it nicely, I'll submit for contrib/.  I
haven't figured out how to include the useful bits of the
top-level Makefile (like SSL setting, which SHA1, -lpthread,
etc.).

		-- Pete

  reply	other threads:[~2010-11-03 22:02 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-31 17:44 index rebuild for cloned repo Pete Wyckoff
2010-10-31 18:07 ` Jonathan Nieder
2010-10-31 19:59 ` [PATCH] cherry-pick/revert: transparently refresh index Jonathan Nieder
2010-10-31 20:26   ` Andreas Schwab
2010-10-31 20:32     ` Jonathan Nieder
2010-10-31 22:26   ` Pete Wyckoff
2010-10-31 22:28     ` [PATCH] teach update-index --refresh about --data-unchanged Pete Wyckoff
2010-11-03 17:37       ` Junio C Hamano
2010-11-03 18:36         ` Jonathan Nieder
2010-11-03 22:02           ` Pete Wyckoff [this message]
2010-11-14 16:58             ` Pete Wyckoff
2010-11-14 17:34               ` Jonathan Nieder
2010-11-01  8:09   ` [PATCH] cherry-pick/revert: transparently refresh index Johannes Sixt
2010-11-03 17:30     ` Junio C Hamano
2010-11-03 20:33       ` Johannes Sixt
2010-11-01  8:44   ` Nguyen Thai Ngoc Duy

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=20101103220243.GA6777@arf.padd.com \
    --to=pw@padd$(echo .)com \
    --cc=chriscool@tuxfamily$(echo .)org \
    --cc=git@vger$(echo .)kernel.org \
    --cc=gitster@pobox$(echo .)com \
    --cc=jrnieder@gmail$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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