From: Nico Schottelius <nico-linuxsetlocalversion@schottelius.org>
To: Christian Kujau <lists@nerdbynature.de>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: [RFC] scripts/setlocalversion on write-protected source tree
Date: Mon, 10 Jun 2013 13:14:45 +0200 [thread overview]
Message-ID: <20130610111445.GA17553@schottelius.org> (raw)
In-Reply-To: <alpine.DEB.2.10.1306091640270.13746@trent.utfs.org>
Hey Christian,
Christian Kujau [Sun, Jun 09, 2013 at 05:50:49PM -0700]:
> Hi,
>
> [errors when using git update-index - different scenarios]
> [...]
>
> On a side note, I don't think a kernel compilation should alter the source
> tree (or the .git directory) in any way and I don't see how removing
> "git update-index" could do any harm. The Mercurial and SVN routines in
> scripts/setlocalversion don't have any tree-modifying commands, AFAICS.
> So, maybe the attached patch would be acceptable.
>
> [...]
As --refresh is being used, I guess (!) the motivation was to update the
index for stat changes that may have taken place elsewhere (like on
NFS) - not sure whether this actually matches (can somebody confirm /
overturn this theory?).
I do however agree with you that setlocalversion should probably not
try to fix this problem, but leave it to the user to update the index,
if necessary.
So I'd personally go for your second patch.
Cheers,
Nico
> diff --git a/scripts/setlocalversion b/scripts/setlocalversion
> index 84b88f1..d105a44 100755
> --- a/scripts/setlocalversion
> +++ b/scripts/setlocalversion
> @@ -71,9 +71,6 @@ scm_version()
> printf -- '-svn%s' "`git svn find-rev $head`"
> fi
>
> - # Update index only on r/w media
> - [ -w . ] && git update-index --refresh --unmerged > /dev/null
> -
> # Check for uncommitted changes
> if git diff-index --name-only HEAD | grep -qv "^scripts/package"; then
> printf '%s' -dirty
--
PGP key: 7ED9 F7D3 6B10 81D7 0EC5 5C09 D7DC C8E4 3187 7DF0
prev parent reply other threads:[~2013-06-10 11:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-10 0:50 Christian Kujau
2013-06-10 11:14 ` Nico Schottelius [this message]
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=20130610111445.GA17553@schottelius.org \
--to=nico-linuxsetlocalversion@schottelius.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lists@nerdbynature.de \
/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
all inboxes | Powered by JetHome®