Re: Can't understand the behaviour of git-diff --submodule

2012-10-28 Thread Francis Moreau
On Sun, Oct 28, 2012 at 1:02 AM, Jens Lehmann jens.lehm...@web.de wrote: Am 26.10.2012 22:43, schrieb Francis Moreau: On Fri, Oct 26, 2012 at 10:05 PM, Jens Lehmann jens.lehm...@web.de wrote: [...] That is weird, git diff --submodule should show that too. Is there anything unusual about your

Re: Mistake in git-reset documentation

2012-10-28 Thread Krzysztof Mazur
On Sat, Oct 27, 2012 at 01:21:18PM +0200, Bojan Petrović wrote: None of the three forms of git-reset accept: git reset which is the equivalent of git reset -mixed. Square brackets should be used instead of parentheses for --soft | --mixed | --hard | --merge | --keep. Bojan Square

Re: Mistake in git-reset documentation

2012-10-28 Thread Bojan Petrović
No need for that. Getting this patched will be enough. :) Thank you! On 28 October 2012 09:36, Krzysztof Mazur krzys...@podlesie.net wrote: On Sat, Oct 27, 2012 at 01:21:18PM +0200, Bojan Petrović wrote: None of the three forms of git-reset accept: git reset which is the equivalent of git

Re: [PATCH] mailmap: avoid out-of-bounds memory access

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 12:49:55AM +0200, Romain Francoise wrote: AddressSanitizer (http://clang.llvm.org/docs/AddressSanitizer.html) complains of a one-byte buffer underflow in parse_name_and_email() while running the test suite. And indeed, if one of the lines in the mailmap begins with '',

Re: Mistake in git-reset documentation

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 09:36:10AM +0100, Krzysztof Mazur wrote: -- 8 -- Subject: [PATCH] doc: git-reset: make --mode optional The git-reset's --mode is an optional argument, however it was documented as required. Signed-off-by: Krzysztof Mazur krzys...@podlesie.net I think this is

Re: [PATCH] Fix t9200 on case insensitive file systems

2012-10-28 Thread Jeff King
On Fri, Oct 26, 2012 at 06:18:24PM +0200, Torsten Bögershausen wrote: t9200 defines $CVSROOT where cvs should init its repository $CVSROOT is set to $PWD/cvsroot. cvs init is supposed to create the repository inside $PWD/cvsroot/CVSROOT cvs init (e.g. version 1.11.23) checks if the last

Re: merge --no-commit not able to report stats more verbosely?

2012-10-28 Thread Jeff King
On Mon, Oct 22, 2012 at 09:39:31AM -0400, Scott R. Godin wrote: As you can see from the below, I can't seem to get it to give me more verbose results of what's being merged (as in the actual merge below) with --stat or -v .. is it supposed to do that? Yes. The diffstat is shown for the

Re: crash on git diff-tree -Ganything tree for new files with textconv filter

2012-10-28 Thread Jeff King
On Sat, Oct 27, 2012 at 08:37:24PM +0200, Peter Oberndorfer wrote: It seems git diff-tree -Ganything tree crashes[1] with a null pointer dereference when run on a commit that adds a file (pdf) with a textconv filter. It can be reproduced with vanilla git by having a commit on top that adds

[PATCH 0/2] textconv support for log -S

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 08:01:04AM -0400, Jeff King wrote: -G operates on the munged data; you can see it feed the munged data to xdiff in diff_grep. But the optimization for handling added and removed files accidentally fed the wrong pointer. Fixing that is a no-brainer, since the

[PATCH 1/2] pickaxe: hoist empty needle check

2012-10-28 Thread Jeff King
If we are given an empty pickaxe needle like git log -S '', it is impossible for us to find anything (because no matter what the content, the count will always be 0). We currently check this at the lowest level of contains(). Let's hoist the logic much earlier to has_changes(), so that it is

[PATCH 2/2] pickaxe: use textconv for -S counting

2012-10-28 Thread Jeff King
We currently just look at raw blob data when using -S to pickaxe. This is mostly historical, as pickaxe predates the textconv feature. If the user has bothered to define a textconv filter, it is more likely that their search string will be on the textconv output, as that is what they will see in

Re: [PATCH] mailmap: avoid out-of-bounds memory access

2012-10-28 Thread Romain Francoise
Jeff King p...@peff.net writes: So you could also check for left == nstart before the loop even begins. I think your fix (to just make the loop more robust to that precondition) is better, though, as the rest of the code does the right thing with such a value of nend. Yep. It looks like

Re: Mistake in git-reset documentation

2012-10-28 Thread Andreas Schwab
Jeff King p...@peff.net writes: On Sun, Oct 28, 2012 at 09:36:10AM +0100, Krzysztof Mazur wrote: DESCRIPTION --- @@ -43,7 +43,7 @@ This means that `git reset -p` is the opposite of `git add -p`, i.e. you can use it to selectively reset hunks. See the ``Interactive Mode''

Re: Mistake in git-reset documentation

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 02:39:49PM +0100, Andreas Schwab wrote: Jeff King p...@peff.net writes: On Sun, Oct 28, 2012 at 09:36:10AM +0100, Krzysztof Mazur wrote: DESCRIPTION --- @@ -43,7 +43,7 @@ This means that `git reset -p` is the opposite of `git add -p`, i.e. you

Re: Mistake in git-reset documentation

2012-10-28 Thread Krzysztof Mazur
On Sun, Oct 28, 2012 at 09:46:35AM -0400, Jeff King wrote: On Sun, Oct 28, 2012 at 02:39:49PM +0100, Andreas Schwab wrote: Jeff King p...@peff.net writes: On Sun, Oct 28, 2012 at 09:36:10AM +0100, Krzysztof Mazur wrote: DESCRIPTION --- @@ -43,7 +43,7 @@ This means

Re: [PATCH] Fix git p4 sync errors

2012-10-28 Thread Pete Wyckoff
arse...@gmail.com wrote on Wed, 24 Oct 2012 19:41 -0700: On Oct 21, 2012, at 12:06 , Junio C Hamano gits...@pobox.com wrote: This solves errors in some cases when syncing renamed files. Can you be a bit more descriptive? What are errors in some case? It might just be when

Re: [PATCH] Fix t9200 on case insensitive file systems

2012-10-28 Thread Torsten Bögershausen
On 28.10.12 12:10, Jeff King wrote: On Fri, Oct 26, 2012 at 06:18:24PM +0200, Torsten Bögershausen wrote: t9200 defines $CVSROOT where cvs should init its repository $CVSROOT is set to $PWD/cvsroot. cvs init is supposed to create the repository inside $PWD/cvsroot/CVSROOT cvs init (e.g.

[PATCH v4 0/8] Fix GIT_CEILING_DIRECTORIES that contain symlinks

2012-10-28 Thread Michael Haggerty
v4 of the series; see the cover letter for v3 [1] for more editorial comments. Changes since v3: * For test-path-utils longest_ancestor_length, normalize all of the paths using normalize_path_copy() to counteract the path mangling carried out by bash on Windows. (Thanks to Johannes Sixt for

[PATCH v4 1/8] Introduce new static function real_path_internal()

2012-10-28 Thread Michael Haggerty
It accepts a new parameter, die_on_error. If die_on_error is false, it simply cleans up after itself and returns NULL rather than dying. Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- abspath.c | 93 --- 1 file changed, 72

[PATCH v4 2/8] real_path_internal(): add comment explaining use of cwd

2012-10-28 Thread Michael Haggerty
Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- abspath.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/abspath.c b/abspath.c index a7ab8e9..f8a526f 100644 --- a/abspath.c +++ b/abspath.c @@ -35,7 +35,14 @@ static const char *real_path_internal(const char *path, int

[PATCH v4 3/8] Introduce new function real_path_if_valid()

2012-10-28 Thread Michael Haggerty
The function is like real_path(), except that it returns NULL on error instead of dying. Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- abspath.c | 5 + cache.h | 1 + 2 files changed, 6 insertions(+) diff --git a/abspath.c b/abspath.c index f8a526f..40cdc46 100644 ---

[PATCH v4 4/8] longest_ancestor_length(): use string_list_split()

2012-10-28 Thread Michael Haggerty
Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- path.c | 18 +++--- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/path.c b/path.c index cbbdf7d..f455e8e 100644 --- a/path.c +++ b/path.c @@ -12,6 +12,7 @@ */ #include cache.h #include strbuf.h +#include

[PATCH v4 5/8] longest_ancestor_length(): take a string_list argument for prefixes

2012-10-28 Thread Michael Haggerty
Change longest_ancestor_length() to take the prefixes argument as a string_list rather than as a colon-separated string. This will make it easier for the caller to alter the entries before calling longest_ancestor_length(). Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- cache.h

[PATCH v4 6/8] longest_ancestor_length(): require prefix list entries to be normalized

2012-10-28 Thread Michael Haggerty
Move the responsibility for normalizing prefixes from longest_ancestor_length() to its callers. Use slightly different normalizations at the two callers: In setup_git_directory_gently_1(), use the old normalization, which ignores paths that are not usable. In the next commit we will change this

Re: git push tags

2012-10-28 Thread Johannes Sixt
Am 25.10.2012 08:58, schrieb Angelo Borsotti: Hello, git push tag updates silently the specified tag. E.g. git init --bare release.git git clone release.git integrator cd integrator git branch -avv touch f1; git add f1; git commit -m A git tag v1 git push origin tag v1 touch f2; git

Re: crash on git diff-tree -Ganything tree for new files with textconv filter

2012-10-28 Thread Peter Oberndorfer
On 2012-10-28 13:01, Jeff King wrote: On Sat, Oct 27, 2012 at 08:37:24PM +0200, Peter Oberndorfer wrote: It seems git diff-tree -Ganything tree crashes[1] with a null pointer dereference when run on a commit that adds a file (pdf) with a textconv filter. It can be reproduced with vanilla

Re: git push tags

2012-10-28 Thread Chris Rorvick
On Sun, Oct 28, 2012 at 1:15 PM, Johannes Sixt j...@kdbg.org wrote: Tags are refs, just like branches. Tags don't move is just a convention, and git doesn't even respect it (except possibly in one place[1]). You can't reseat tags unless you use -f, which is exactly the same with branches,

[PATCH] Documentation: improve the example of overriding LESS via core.pager

2012-10-28 Thread Patrick Palka
You can override an option set in the LESS variable by simply prefixing the command line option with `-+`. This is more robust than the previous example if the default LESS options are to ever change. Signed-off-by: Patrick Palka patr...@parcs.ath.cx --- Documentation/config.txt |8

Re: [PATCH v2] git-submodule add: Add -r/--record option.

2012-10-28 Thread Jens Lehmann
Am 25.10.2012 02:53, schrieb W. Trevor King: On Wed, Oct 24, 2012 at 09:15:32PM +0200, Jens Lehmann wrote: I still fail to see what adding that functionality to the submodule command buys us (unless we also add code which really uses the branch setting). What's wrong with doing a simple:

Re: [PATCHv3 0/2] Teach --recursive to submodule sync

2012-10-28 Thread Jens Lehmann
Am 26.10.2012 21:44, schrieb Phil Hord: [PATCHv3 1/2] Teach --recursive to submodule sync Now with less noise and no redundant flags passed to the recursive call. [PATCHv3 2/2] Add tests for submodule sync --recursive The test remains unchanged. Both are looking good. Acked-By: Jens

[PATCH] pathspec.c: Fix some sparse warnings

2012-10-28 Thread Ramsay Jones
Sparse issues a warning for all six external symbols defined in this file. In order to suppress the warnings, we include the 'pathspec.h' header file, which contains the relevant extern declarations for these symbols. Signed-off-by: Ramsay Jones ram...@ramsay1.demon.co.uk --- Hi Nguyen, I

Re: [PATCH v2] git-submodule add: Add -r/--record option.

2012-10-28 Thread W. Trevor King
On Sun, Oct 28, 2012 at 09:48:18PM +0100, Jens Lehmann wrote: Am 25.10.2012 02:53, schrieb W. Trevor King: On Wed, Oct 24, 2012 at 09:15:32PM +0200, Jens Lehmann wrote: I still fail to see what adding that functionality to the submodule command buys us (unless we also add code which really

Removing unreachable objects in the presence of broken links?

2012-10-28 Thread Geert Uytterhoeven
Hi, I managed to have a few missing objects in my development Linux kernel repository, which uses another Linux kernel clone as an alternate. Fortunately nothing is lost, as all missing objects are unreachable. Probably they were in a branch that has been rebased, and the objects existed for a

Re: Removing unreachable objects in the presence of broken links?

2012-10-28 Thread Andreas Schwab
Geert Uytterhoeven ge...@linux-m68k.org writes: Is there a way to force removing unreachable objects in the presence of broken links? Does it help to forcibly expire the reflogs? Andreas. -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B

[PATCH] submodule status: remove unused orig_* variables

2012-10-28 Thread Jens Lehmann
When renaming orig_args to orig_flags in 98dbe63d (submodule: only preserve flags across recursive status/update invocations) the call site of the recursive cmd_status was forgotten. At that place orig_args is still passed into the recursion, which is always empty since then. This did not break

Re: git push tags

2012-10-28 Thread Philip Oakley
From: Chris Rorvick ch...@rorvick.com Sent: Sunday, October 28, 2012 7:59 PM On Sun, Oct 28, 2012 at 1:15 PM, Johannes Sixt j...@kdbg.org wrote: Tags are refs, just like branches. Tags don't move is just a convention, and git doesn't even respect it (except possibly in one place[1]). You can't

Re: [PATCH v2] git-submodule add: Add -r/--record option.

2012-10-28 Thread Shawn Pearce
On Sun, Oct 28, 2012 at 1:48 PM, Jens Lehmann jens.lehm...@web.de wrote: Am 23.10.2012 22:55, schrieb W. Trevor King: As Phil pointed out, doing anything with this variable is ambiguous: On Mon, Oct 22, 2012 at 06:03:53PM -0400, Phil Hord wrote: Some projects now use the 'branch' config value

Re: [PATCH v2] git-submodule add: Add -r/--record option.

2012-10-28 Thread W. Trevor King
On Sun, Oct 28, 2012 at 02:59:33PM -0700, Shawn Pearce wrote: Looks like the Gerrit meaning is basically the same as Ævar's. Gerrit updates the parent project as if you had done: $ git submodule foreach 'git checkout $(git config --file $toplevel/.gitmodules submodule.$name.branch) git

[PATCH] Teach rm to remove submodules when given with a trailing '/'

2012-10-28 Thread Jens Lehmann
Doing a git rm submod/ on a submodule results in an error: fatal: pathspec 'submod/' did not match any files This is really inconvenient as e.g. using TAB completion in a shell on a submodule automatically adds the trailing '/' when it completes the path of the submodule directory. The

Re: git push tags

2012-10-28 Thread Drew Northup
On Sun, Oct 28, 2012 at 5:49 PM, Philip Oakley philipoak...@iee.org wrote: If I read it right it was where two users can tag two different commits with the same tag name [e.g. 'Release_V3.3'] and the last person to push wins, so anyone in the team can change what is to be the released version!

gitweb

2012-10-28 Thread rh
I'm not using gitweb I was thinking about using it and was looking at the cgi and saw this in this file: https://github.com/git/git/blob/master/gitweb/gitweb.perl I think I understand the intention but the outcome is wrong. our %highlight_ext = ( # main extensions, defining name of

Re: [PATCH v3 0/8] Fix GIT_CEILING_DIRECTORIES that contain symlinks

2012-10-28 Thread David Aguilar
On Sat, Oct 20, 2012 at 11:51 PM, Junio C Hamano gits...@pobox.com wrote: Michael Haggerty mhag...@alum.mit.edu writes: This patch series has the side effect that all of the directories listed in GIT_CEILING_DIRECTORIES are accessed *unconditionally* to resolve any symlinks that are present

Re: [PATCH v3 0/8] Fix GIT_CEILING_DIRECTORIES that contain symlinks

2012-10-28 Thread Junio C Hamano
David Aguilar dav...@gmail.com wrote: Is there another way to accomplish this without the performance hit? Perhaps not canonicalize elements on the CEILING list ourselves? If we make it a user error to put symlinked alias in the variable, and document it clearly, wouldn't it suffice? -- To

Re: git push tags

2012-10-28 Thread Chris Rorvick
On Sun, Oct 28, 2012 at 4:49 PM, Philip Oakley philipoak...@iee.org wrote: From: Chris Rorvick ch...@rorvick.com Sent: Sunday, October 28, 2012 7:59 PM On Sun, Oct 28, 2012 at 1:15 PM, Johannes Sixt j...@kdbg.org wrote: Tags are refs, just like branches. Tags don't move is just a

Re: [PATCH v3 0/8] Fix GIT_CEILING_DIRECTORIES that contain symlinks

2012-10-28 Thread Michael Haggerty
On 10/29/2012 01:15 AM, David Aguilar wrote: On Sat, Oct 20, 2012 at 11:51 PM, Junio C Hamano gits...@pobox.com wrote: Michael Haggerty mhag...@alum.mit.edu writes: This patch series has the side effect that all of the directories listed in GIT_CEILING_DIRECTORIES are accessed

Re: gitweb

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 04:56:47PM -0700, rh wrote: I'm not using gitweb I was thinking about using it and was looking at the cgi and saw this in this file: https://github.com/git/git/blob/master/gitweb/gitweb.perl I think I understand the intention but the outcome is wrong. our

Re: [PATCH v2] git-submodule add: Add -r/--record option.

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 06:34:31PM -0400, W. Trevor King wrote: On Sun, Oct 28, 2012 at 02:59:33PM -0700, Shawn Pearce wrote: Looks like the Gerrit meaning is basically the same as Ævar's. Gerrit updates the parent project as if you had done: $ git submodule foreach 'git checkout

Re: Mistake in git-reset documentation

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 03:13:27PM +0100, Krzysztof Mazur wrote: The --mixed mode is also described as second mode, and saying that --mixed is default earlier may save some time wasted on reading --soft description. There is also small inconsequence in what mode is, just mixed or --mixed.

Re: [PATCH] pathspec.c: Fix some sparse warnings

2012-10-28 Thread Jeff King
On Sun, Oct 28, 2012 at 09:09:19PM +, Ramsay Jones wrote: I asked Adam to squash this patch into his 'as/check-ignore' branch when he next re-rolled the branch. However, it appears that you resubmitted that branch instead ... :-D I don't know if this branch is ready to progress to next