Re: Anomalous AUTHOR and DOCUMENTATION sections in manpages

2014-01-22 Thread Johan Herland
and, on the other hand, hundreds of contributors. Would the mentioned authors (CCed) consent to the removal of these sections? No problem from me. No problems here. -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body

Re: Having Git follow symlinks

2014-01-28 Thread Johan Herland
into your dotfiles repo. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: git-note -C changes commit type?

2014-02-11 Thread Johan Herland
), and keep everything alive/reachable/shareable that way... Hope this helps, ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: git-note -C changes commit type?

2014-02-12 Thread Johan Herland
On Wed, Feb 12, 2014 at 1:06 AM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: There is currently no way the git notes commands will allow you to store the 3d7de37 commit object directly as a note. There is also (AFAICS) no easy workaround (git fast-import

[PATCH] notes: Disallow reusing non-blob as a note object

2014-02-12 Thread Johan Herland
-c/-C is passed to git notes append (which appends the $object contents to an existing note object). In both cases, passing a non-blob $object does not make sense. Also add a couple of tests demonstrating expected behavior. Suggested-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland

Re: git-note -C changes commit type?

2014-02-12 Thread Johan Herland
On Wed, Feb 12, 2014 at 9:53 AM, Joachim Breitner m...@joachim-breitner.de wrote: Am Mittwoch, den 12.02.2014, 00:52 +0100 schrieb Johan Herland: You would have a notes ref refs/notes/history whose tree would contain an entry named e1bfac434ebd3135a3784f6fc802f235098eebd0 pointing

Re: [PATCH 5/5] implement @{publish} shorthand

2014-02-18 Thread Johan Herland
there is a reason not to reuse the push/pull terminology for these concepts, but if there is, I guess we could instead call them @{source}/@{destination}, @{src}/@{dst}, or @{from}/@{to}, or somesuch... -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line

Re: [RFC/PATCH] Supporting non-blob notes

2014-02-18 Thread Johan Herland
at notes-as-trees. The first consequence of this is probably that your added -o/--object option should be renamed. -t/--tree is not taken, AFAICS... Johan Herland wrote: Obviously, it would not make sense to use refs/notes/history while displaying the commit log (git log --notes=history), as the raw

Re: [RFC/PATCH] Supporting non-blob notes

2014-02-23 Thread Johan Herland
On Wed, Feb 19, 2014 at 12:10 AM, Duy Nguyen pclo...@gmail.com wrote: On Tue, Feb 18, 2014 at 9:46 PM, Johan Herland jo...@herland.net wrote: On Mon, Feb 17, 2014 at 11:48 AM, yann.dir...@bertin.fr wrote: The recent git-note -C changes commit type? thread (http://thread.gmane.org

Re: [RFC/PATCH] Supporting non-blob notes

2014-02-24 Thread Johan Herland
On Mon, Feb 24, 2014 at 11:27 AM, ydir...@free.fr wrote: Johan Herland jo...@herland.net wrote on 02/24/2014 02:29:10: I've been thinking about this for a while now, and I find myself agreeing more and more with Junio's argument in the linked thread. I think notes are fundamentally - like

Re: [PATCH] git submodule foreach: Skip eval for more than one argument

2014-03-04 Thread Johan Herland
quotes? ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] git submodule foreach: Skip eval for more than one argument

2014-03-04 Thread Johan Herland
On Tue, Mar 4, 2014 at 3:57 PM, Matthijs Kooijman matth...@stdin.nl wrote: On Tue, Mar 04, 2014 at 03:53:24PM +0100, Johan Herland wrote: What would you expect echo '$name' to do? If I run git submodule foreach each '$name', then my shell eats the single quotes (which are only to prevent my

Re: [RFC/WIP] Pluggable reference backends

2014-03-10 Thread Johan Herland
and the plan you have for how to get there. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: question about: Facebook makes Mercurial faster than Git

2014-03-10 Thread Johan Herland
the same way Mercurial does. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 05/26] t1400: Add some more tests involving quoted arguments

2014-03-10 Thread Johan Herland
On Mon, Mar 10, 2014 at 1:46 PM, Michael Haggerty mhag...@alum.mit.edu wrote: Previously there were no good tests of C-quoted arguments. Signed-off-by: Michael Haggerty mhag...@alum.mit.edu FWIW, the first 5 patches seem trivially correct to me. Feel free to add: Reviewed-by: Johan Herland jo

Possible regression in master? (submodules without a master branch)

2014-03-27 Thread Johan Herland
King: submodule: explicit local branch creation in module_clone). Looking at the patch, it seems to introduce an implicit assumption on the submodule origin having a master branch. Is this an intended change in behaviour? ...Johan -- Johan Herland, jo...@herland.net www.herland.net

Re: Re: Possible regression in master? (submodules without a master branch)

2014-03-27 Thread Johan Herland
: On Thu, Mar 27, 2014 at 06:31:27PM +0100, Jens Lehmann wrote: Am 27.03.2014 18:16, schrieb Junio C Hamano: Johan Herland jo...@herland.net writes: I just found a failure to checkout a project with submodules where there is no explicit submodule branch configuration, and the submodules

Re: Possible regression in master? (submodules without a master branch)

2014-03-27 Thread Johan Herland
' is somewhat analogous to unset branch.name.merge while pulling. I.e. you have told me to merge/rebase, but you have not told me against which branch, therefore error out. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git

Re: [RFC] t7410: 210 tests for various 'git submodule update' scenarios

2014-04-17 Thread Johan Herland
PM, W. Trevor King wk...@tremily.us wrote: On Wed, Apr 16, 2014 at 02:54:48AM +0200, Johan Herland wrote: This is a work-in-progress to flesh out (and promote discussion about) the expected behaviors for all possible scenarios in which 'git submodule update' might be run. This is lovely

Re: [ANNOUNCE] Git v2.0.0-rc0

2014-04-18 Thread Johan Herland
-- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH] git-svn.txt: Retain a description og pre-v2.0 default prefix

2014-04-19 Thread Johan Herland
Add a description of =1.9 behavior in the manpage. Users on long-term-support systems are likely to continue using ancient git installations for some time (5-10 years, even?), but may come across the current documentation online. Suggested-by: Eric Wong normalper...@yhbt.net Signed-off-by: Johan

Re: [ANNOUNCE] Git v2.0.0-rc0

2014-04-23 Thread Johan Herland
the old default, you can get it by passing +'--prefix ' on the command line ('--prefix=' may not work if +your Perl's Getopt::Long is v2.37). --ignore-paths=regex;; When passed to 'init' or 'clone' this regular expression will ...Johan -- Johan Herland, jo...@herland.net

Re: Recording the current branch on each commit?

2014-04-27 Thread Johan Herland
above), and provide some tools that demonstrate the added value of this information. If that is successful and gains momentum, the git community can certainly reconsider whether it makes sense to fold it into a more formalized part of the commit object. ...Johan -- Johan Herland, jo

Re: Recording the current branch on each commit?

2014-04-27 Thread Johan Herland
On Sun, Apr 27, 2014 at 7:38 PM, Jeremy Morton ad...@game-point.net wrote: On 27/04/2014 10:09, Johan Herland wrote: On Sun, Apr 27, 2014 at 1:56 AM, Jeremy Mortonad...@game-point.net wrote: Currently, git records a checksum, author, commit date/time, and commit message with every commit

Re: Recording the current branch on each commit?

2014-04-27 Thread Johan Herland
On Sun, Apr 27, 2014 at 10:55 PM, Jeremy Morton ad...@game-point.net wrote: On 27/04/2014 20:33, Johan Herland wrote: On Sun, Apr 27, 2014 at 7:38 PM, Jeremy Mortonad...@game-point.net wrote: On 27/04/2014 10:09, Johan Herland wrote: As far as I can tell from that discussion, the general

Re: Recording the current branch on each commit?

2014-04-28 Thread Johan Herland
hook itself into the user's .git/hooks/ dir. 3. Tell your co-workers to run the post-checkout hook script manually the first time. After that, the script should take care of updating itself and any hooks that you add to the project. ...Johan -- Johan Herland, jo...@herland.net www.herland.net

Re: Recording the current branch on each commit?

2014-04-28 Thread Johan Herland
On Mon, Apr 28, 2014 at 12:03 PM, Sitaram Chamarty sitar...@gmail.com wrote: Johan Herland jo...@herland.net writes: Obviously, the feature would necessarily have to be optional, simply because Git would have to keep understanding the old commit object format for a LONG time (probably

Re: [PATCH] Standardize python shebangs

2014-05-07 Thread Johan Herland
(for python2-only scripts) '/usr/bin/env python2' is the way to go. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo

Re: [PATCH] Standardize python shebangs

2014-05-07 Thread Johan Herland
On Wed, May 7, 2014 at 1:11 PM, Felipe Contreras felipe.contre...@gmail.com wrote: Johan Herland wrote: On Wed, May 7, 2014 at 12:03 PM, Felipe Contreras felipe.contre...@gmail.com wrote: It's better if all our scripts use the same '/usr/bin/env python'. Only if they are source compatible

Re: [PATCH] Standardize python shebangs

2014-05-08 Thread Johan Herland
Python2 for that. FWIW, the rules laid out in PEP394 should be very easy to follow: - If your script is Python2-only, use #!/usr/bin/env python2 - If your script is Python3-only, use #!/usr/bin/env python3 - If your script is Python2/3-agnostic, use #!/usr/bin/env python ...Johan -- Johan

Re: [PATCH] remote-helpers: point at their upstream repositories

2014-05-20 Thread Johan Herland
recipe) for git-imerge: https://aur.archlinux.org/packages/git-imerge-git/ ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: [PATCH] Improve English grammar

2014-08-30 Thread Johan Herland
On Sat, Aug 30, 2014 at 9:56 PM, Alex Henrie alexhenri...@gmail.com wrote: Hi, I submitted this patch a week ago and got no reply, so I'm sending it again and CC'ing the original authors this time... Signed-off-by: Alex Henrie alexhenri...@gmail.com Looks good to me. Acked-by: Johan Herland

[RFC/PATCH 3/3] revert/cherry-pick --no-verify: Update documentation

2014-09-03 Thread Johan Herland
Add --no-verify to the revert and cherry-pick man pages. Also mention revert and cherry-pick in the corresponding documentation for the pre-commit and commit-msg hooks. Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-cherry-pick.txt | 4 Documentation/git-revert.txt

[RFC/PATCH 2/3] revert/cherry-pick: Add --no-verify option, and pass it on to commit

2014-09-03 Thread Johan Herland
t7503/t7504 test cases added previously. Signed-off-by: Johan Herland jo...@herland.net --- builtin/revert.c | 1 + sequencer.c| 7 +++ sequencer.h| 1 + t/t7503-pre-commit-hook.sh | 4 ++-- t/t7504-commit-msg-hook.sh | 4 ++-- 5 files changed, 13

[RFC/PATCH 1/3] t7503/4: Add failing testcases for revert/cherry-pick --no-verify

2014-09-03 Thread Johan Herland
the --no-verify option is supposed when it is added to revert and cherry-pick (in the next patch). Signed-off-by: Johan Herland jo...@herland.net --- t/t7503-pre-commit-hook.sh | 24 t/t7504-commit-msg-hook.sh | 24 2 files changed, 48 insertions(+) diff --git

[RFC/PATCH 0/3] Teach revert/cherry-pick the --no-verify option

2014-09-03 Thread Johan Herland
A colleague of mine noticed that cherry-pick does not accept the --no-verify option to skip running the pre-commit/commit-msg hooks. Here's a first attempt at adding --no-verify to the revert/cherry-pick. Have fun! :) ...Johan Johan Herland (3): t7503/4: Add failing testcases for revert

Re: [RFC/PATCH 2/3] revert/cherry-pick: Add --no-verify option, and pass it on to commit

2014-09-04 Thread Johan Herland
On Wed, Sep 3, 2014 at 9:32 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: diff --git a/builtin/revert.c b/builtin/revert.c index f9ed5bd..831c2cd 100644 --- a/builtin/revert.c +++ b/builtin/revert.c @@ -91,6 +91,7 @@ static void parse_args(int argc

Re: [RFC/PATCH 0/3] Teach revert/cherry-pick the --no-verify option

2014-09-08 Thread Johan Herland
for the noise. Hopefully, I will learn not to blindly follow my assumptions. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org

Re: [PATCH] git-notes.txt: Explain how to transfer notes between repos

2014-09-10 Thread Johan Herland
this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body

Re: [PATCH] notes: accept any ref for merge

2014-09-19 Thread Johan Herland
with the corresponding local notes ref Have fun! :) ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] notes: accept any ref for merge

2014-09-19 Thread Johan Herland
On Fri, Sep 19, 2014 at 8:22 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: On Fri, Sep 19, 2014 at 11:39 AM, Jeff King p...@peff.net wrote: On Fri, Sep 19, 2014 at 09:39:45AM +0200, Scott Chacon wrote: Currently if you try to merge notes, the notes code

Re: Bug/request: the empty string should be a valid git note

2014-09-20 Thread Johan Herland
was surprised to see that this behavior was deliberately introduced: git log -1 a0b4dfa commit a0b4dfa9b35a2ebac578ea5547b041bb78557238 Author: Johan Herland jo...@herland.net Date: Sat Feb 13 22:28:24 2010 +0100 Teach builtin-notes to remove empty notes When

[RFC/PATCH] notes: Allow adding empty notes with -C

2014-09-20 Thread Johan Herland
$empty_blob. Reported-by: James H. Fisher j...@trifork.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 16 +++- notes.c | 3 +-- t/t3301-notes.sh | 19 +++ 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/builtin/notes.c b

Re: [RFC/PATCH] notes: Allow adding empty notes with -C

2014-09-21 Thread Johan Herland
On Sun, Sep 21, 2014 at 10:53 AM, Torsten Bögershausen tbo...@web.de wrote: On 2014-09-21 05.00, Johan Herland wrote: [...] +cat expect EOF Git style for shell scripts: Plase put no space between or or and the file name: cat expect EOF [...] + git log -1 actual git log -1

Re: fsck option to remove corrupt objects - why/why not?

2014-10-16 Thread Johan Herland
-reachable history), is more involved than simply calling out to git fetch... ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: fsck option to remove corrupt objects - why/why not?

2014-10-16 Thread Johan Herland
On Thu, Oct 16, 2014 at 2:25 PM, Jeff King p...@peff.net wrote: On Thu, Oct 16, 2014 at 11:04:04AM +0200, Johan Herland wrote: I simply copied the packfile containing the good copy into the corrupted repo, and then ran a git gc, which happened to use the good copy of the corrupted object

[PATCH 1/2] t3312-notes-empty: Test that 'git notes' removes empty notes by default

2014-11-04 Thread Johan Herland
Add test cases documenting the current behavior when trying to add/append/edit empty notes. This is in preparation for adding --allow-empty; to allow empty notes to be stored. Signed-off-by: Johan Herland jo...@herland.net --- t/t3312-notes-empty.sh | 58

[PATCH 2/2] notes: Add --allow-empty, to allow storing empty notes

2014-11-04 Thread Johan Herland
Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-notes.txt | 12 builtin/notes.c | 25 +++-- notes.c | 3 +-- t/t3312-notes-empty.sh | 20 +++- 4 files changed, 43 insertions(+), 17 deletions

[PATCHv2 1/3] builtin/notes: Fix premature failure when trying to add the empty blob

2014-11-05 Thread Johan Herland
was given (e.g. using -m or -F /dev/null). The next patch contains a test that verifies the fixed behavior. Found-by: Eric Sunshine sunsh...@sunshineco.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin

Re: [PATCH 1/2] t3312-notes-empty: Test that 'git notes' removes empty notes by default

2014-11-05 Thread Johan Herland
[...] Each -c/-C case fails for me when trying to read $empty_object. For example: fatal: Failed to read object 'e69de29bb2d1d6434b8b29ae775ad8c2e48c5391'. not ok 5 - 'git notes add -c $empty_blob' removes empty note These are all fixed in the re-roll. Thanks for the feedback! ...Johan -- Johan

[PATCHv2 2/3] t3312-notes-empty: Test that 'git notes' removes empty notes by default

2014-11-05 Thread Johan Herland
Add test cases documenting the current behavior when trying to add/append/edit empty notes. This is in preparation for adding --allow-empty; to allow empty notes to be stored. Improved-by: Eric Sunshine sunsh...@sunshineco.com Signed-off-by: Johan Herland jo...@herland.net --- t/t3312-notes

[PATCHv2 3/3] notes: Add --allow-empty, to allow storing empty notes

2014-11-05 Thread Johan Herland
Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-notes.txt | 12 builtin/notes.c | 23 ++- notes.c | 3 +-- t/t3312-notes-empty.sh | 17 - 4 files changed, 39 insertions(+), 16 deletions

Re: [PATCHv2 2/3] t3312-notes-empty: Test that 'git notes' removes empty notes by default

2014-11-07 Thread Johan Herland
On Wed, Nov 5, 2014 at 8:00 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: +verify_missing() { + git log -1 actual Hmph, it was unclear what exactly you are trying to check with this one and the other git log -1 expect_missing. Perhaps a comment

[PATCHv3 0/5] Handling empty notes

2014-11-07 Thread Johan Herland
(#4) - Add a final (optional) patch with some whitespace and other cleanups in t3301. Feel free to drop this if it's too much churn. Have fun! :) ...Johan Johan Herland (5): builtin/notes: Fix premature failure when trying to add the empty blob t3301: Verify that 'git notes' removes

[PATCHv3 3/5] builtin/notes: Add --allow-empty, to allow storing empty notes

2014-11-07 Thread Johan Herland
Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-notes.txt | 12 builtin/notes.c | 23 ++- t/t3301-notes.sh| 10 +- 3 files changed, 31 insertions(+), 14 deletions

[PATCHv3 2/5] t3301: Verify that 'git notes' removes empty notes by default

2014-11-07 Thread Johan Herland
Add test cases documenting the current behavior when trying to add/append/edit empty notes. This is in preparation for adding --allow-empty; to allow empty notes to be stored. Improved-by: Eric Sunshine sunsh...@sunshineco.com Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan

[PATCHv3 1/5] builtin/notes: Fix premature failure when trying to add the empty blob

2014-11-07 Thread Johan Herland
was given (e.g. using -m or -F /dev/null). The next patch contains a test that verifies the fixed behavior. Found-by: Eric Sunshine sunsh...@sunshineco.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin

[PATCHv3 4/5] notes: Empty notes should be shown by 'git log'

2014-11-07 Thread Johan Herland
If the user has gone through the trouble of explicitly adding an empty note, then git log should not silently skip it (as if it didn't exist). Signed-off-by: Johan Herland jo...@herland.net --- notes.c | 3 +-- t/t3301-notes.sh | 12 2 files changed, 13 insertions(+), 2

[PATCHv3 5/5] t3301: Use write_script(), nitpick whitespace

2014-11-07 Thread Johan Herland
Signed-off-by: Johan Herland jo...@herland.net --- Drop this if it's too much churn. ...Johan t/t3301-notes.sh | 254 +++ 1 file changed, 126 insertions(+), 128 deletions(-) diff --git a/t/t3301-notes.sh b/t/t3301-notes.sh index f5d8193

[PATCHv4 0/9] Handling empty notes

2014-11-09 Thread Johan Herland
! :) ...Johan Johan Herland (9): builtin/notes: Fix premature failure when trying to add the empty blob t3301: Verify that 'git notes' removes empty notes by default builtin/notes: Improve naming builtin/notes: Refactor note file path into struct note_data builtin/notes: Simplify early exit

[PATCHv4 1/9] builtin/notes: Fix premature failure when trying to add the empty blob

2014-11-09 Thread Johan Herland
was given (e.g. using -m or -F /dev/null). The next patch contains a test that verifies the fixed behavior. Found-by: Eric Sunshine sunsh...@sunshineco.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin

[PATCHv4 6/9] builtin/notes: Split create_note() to clarify add vs. remove logic

2014-11-09 Thread Johan Herland
()), keeping the logic for writing the actual note object in a separate function: write_note_data(). Suggested-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 103 +--- 1 file changed, 54

Re: [PATCHv3 3/5] builtin/notes: Add --allow-empty, to allow storing empty notes

2014-11-09 Thread Johan Herland
On Fri, Nov 7, 2014 at 7:04 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: [...] Assuming that it is a good idea to allow empty notes, I think there are two issues involved here: * Traditionally, feeding an empty note is taken as a request to remove

[PATCHv4 8/9] notes: Empty notes should be shown by 'git log'

2014-11-09 Thread Johan Herland
If the user has gone through the trouble of explicitly adding an empty note, then git log should not silently skip it (as if it didn't exist). Signed-off-by: Johan Herland jo...@herland.net --- notes.c | 3 +-- t/t3301-notes.sh | 12 2 files changed, 13 insertions(+), 2

[PATCHv4 2/9] t3301: Verify that 'git notes' removes empty notes by default

2014-11-09 Thread Johan Herland
Add test cases documenting the current behavior when trying to add/append/edit empty notes. This is in preparation for adding --allow-empty; to allow empty notes to be stored. Improved-by: Eric Sunshine sunsh...@sunshineco.com Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan

[PATCHv4 9/9] t3301: Modernize

2014-11-09 Thread Johan Herland
...@sunshineco.com Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- t/t3301-notes.sh | 1148 +- 1 file changed, 522 insertions(+), 626 deletions(-) diff --git a/t/t3301-notes.sh b/t/t3301-notes.sh index 416ed9e

[PATCHv4 4/9] builtin/notes: Refactor note file path into struct note_data

2014-11-09 Thread Johan Herland
Move the 'path' variable from create_note() and into the note_data struct. Unify cleanup of note_data objects with a free_note_data() function. This might not make too much sense on its own, but it makes the future refactoring of create_note() considerably cleaner. Signed-off-by: Johan Herland

[PATCHv4 3/9] builtin/notes: Improve naming

2014-11-09 Thread Johan Herland
write_note_data() to copy_obj_to_fd(), which more aptly describes what it actually does: Copying the contents of a git object (given by its SHA1) into a given file descriptor. Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 109 1

[PATCHv4 5/9] builtin/notes: Simplify early exit code in add()

2014-11-09 Thread Johan Herland
Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/builtin/notes.c b/builtin/notes.c index 1017472..f1480cf 100644 --- a/builtin/notes.c +++ b/builtin/notes.c @@ -399,7 +399,7 @@ static int

[PATCHv4 7/9] builtin/notes: Add --allow-empty, to allow storing empty notes

2014-11-09 Thread Johan Herland
Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-notes.txt | 12 builtin/notes.c | 17 +++-- t/t3301-notes.sh| 10 +- 3 files changed, 28 insertions(+), 11 deletions(-) diff

Re: [PATCHv4 5/9] builtin/notes: Simplify early exit code in add()

2014-11-10 Thread Johan Herland
On Mon, Nov 10, 2014 at 9:36 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/builtin/notes.c b/builtin

Re: [PATCHv4 9/9] t3301: Modernize

2014-11-10 Thread Johan Herland
On Mon, Nov 10, 2014 at 9:42 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: Make this test script appear somewhat less old-fashioned: - Use test helper functions: - write_script - test_commit - test_write_lines - test_config

Re: mac test failure -- test 3301

2014-11-10 Thread Johan Herland
^ test_must_fail git notes show HEAD^ ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCHv4 9/9] t3301: Modernize

2014-11-10 Thread Johan Herland
On Tue, Nov 11, 2014 at 2:07 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Mon, Nov 10, 2014 at 8:04 PM, Johan Herland jo...@herland.net wrote: On Mon, Nov 10, 2014 at 9:42 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: Make this test script appear

Re: mac test failure -- test 3301

2014-11-11 Thread Johan Herland
On Tue, Nov 11, 2014 at 3:41 AM, Jeff King p...@peff.net wrote: On Tue, Nov 11, 2014 at 02:40:19AM +0100, Johan Herland wrote: This and all other failures are due to the output of 'wc -l', which on Mac is {whitespace}1 rather than just 1 as it is on other platforms. fbe4f748 added quotes

[PATCHv5 0/9] Handling empty notes

2014-11-11 Thread Johan Herland
! :) ...Johan Johan Herland (9): builtin/notes: Fix premature failure when trying to add the empty blob t3301: Verify that 'git notes' removes empty notes by default builtin/notes: Improve naming builtin/notes: Refactor note file path into struct note_data builtin/notes: Simplify early exit code

[PATCHv5 4/9] builtin/notes: Refactor note file path into struct note_data

2014-11-11 Thread Johan Herland
Move the 'path' variable from create_note() and into the note_data struct. Unify cleanup of note_data objects with a free_note_data() function. This might not make too much sense on its own, but it makes the future refactoring of create_note() considerably cleaner. Signed-off-by: Johan Herland

[PATCHv5 3/9] builtin/notes: Improve naming

2014-11-11 Thread Johan Herland
write_note_data() to copy_obj_to_fd(), which more aptly describes what it actually does: Copying the contents of a git object (given by its SHA1) into a given file descriptor. Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 109 1

[PATCHv5 7/9] builtin/notes: Add --allow-empty, to allow storing empty notes

2014-11-11 Thread Johan Herland
Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- Documentation/git-notes.txt | 12 builtin/notes.c | 17 +++-- t/t3301-notes.sh| 10 +- 3 files changed, 28 insertions(+), 11 deletions(-) diff

[PATCHv5 1/9] builtin/notes: Fix premature failure when trying to add the empty blob

2014-11-11 Thread Johan Herland
was given (e.g. using -m or -F /dev/null). The next patch contains a test that verifies the fixed behavior. Found-by: Eric Sunshine sunsh...@sunshineco.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin

[PATCHv5 8/9] notes: Empty notes should be shown by 'git log'

2014-11-11 Thread Johan Herland
If the user has gone through the trouble of explicitly adding an empty note, then git log should not silently skip it (as if it didn't exist). Signed-off-by: Johan Herland jo...@herland.net --- notes.c | 3 +-- t/t3301-notes.sh | 12 2 files changed, 13 insertions(+), 2

[PATCHv5 5/9] builtin/notes: Simplify early exit code in add()

2014-11-11 Thread Johan Herland
Remove the need for 'retval' and the unnecessary goto. Also reorganize to only call free_note_data() is actually needed. Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 35 +-- 1 file changed, 17

[PATCHv5 6/9] builtin/notes: Split create_note() to clarify add vs. remove logic

2014-11-11 Thread Johan Herland
()), keeping the logic for writing the actual note object in a separate function: write_note_data(). Suggested-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- builtin/notes.c | 103 +--- 1 file changed, 54

[PATCHv5 2/9] t3301: Verify that 'git notes' removes empty notes by default

2014-11-11 Thread Johan Herland
Add test cases documenting the current behavior when trying to add/append/edit empty notes. This is in preparation for adding --allow-empty; to allow empty notes to be stored. Improved-by: Eric Sunshine sunsh...@sunshineco.com Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan

[PATCHv5 9/9] t3301: Modernize

2014-11-11 Thread Johan Herland
and verification. Improved-by: Eric Sunshine sunsh...@sunshineco.com Improved-by: Junio C Hamano gits...@pobox.com Improved-by: Michael Blume blume.m...@gmail.com Improved-by: Jeff King p...@peff.net Signed-off-by: Johan Herland jo...@herland.net --- t/t3301-notes.sh | 1300

Re: [PATCHv5 9/9] t3301: Modernize

2014-11-12 Thread Johan Herland
On Wed, Nov 12, 2014 at 2:57 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Tue, Nov 11, 2014 at 7:40 PM, Johan Herland jo...@herland.net wrote: + test_line_count = 1 actual Broken -chain. This problem is repeated each place use invoke test_line_count(). Thanks. Fixed in the next

Re: [PATCHv5 9/9] t3301: Modernize

2014-11-12 Thread Johan Herland
On Wed, Nov 12, 2014 at 10:18 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: On Wed, Nov 12, 2014 at 2:57 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Tue, Nov 11, 2014 at 7:40 PM, Johan Herland jo...@herland.net wrote: + test_line_count = 1

Re: how to reduce disk usage for large .git dirs?

2014-11-13 Thread Johan Herland
|B pulls, they will find most objects are already present in repo-master. ...Johan -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: Notes and submodules

2013-08-19 Thread Johan Herland
be removed when running git notes prune in the super project. -- Johan Herland, jo...@herland.net www.herland.net -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: Notes and submodules

2013-08-20 Thread Johan Herland
On Tue, Aug 20, 2013 at 10:39 AM, Francis Moreau francis.m...@gmail.com wrote: On Mon, Aug 19, 2013 at 3:55 PM, Johan Herland jo...@herland.net wrote: On Mon, Aug 19, 2013 at 10:13 AM, Francis Moreau francis.m...@gmail.com wrote: Is it possible to keep submodules notes in the super project

[PATCH 0/5] branch: Fix --track on a remote-tracking non-branch

2013-09-06 Thread Johan Herland
the breakage), and the actual fix (which simply removes the extra refs/heads/* requirement on the remote ref) is in patch #5/5. The two first patches are unrelated trivial fixes that I encountered while working on this, and patch #3 is a small documentation update suggested by Per. ...Johan Johan

[PATCH 2/5] t3200: Minor fix when preparing for tracking failure

2013-09-06 Thread Johan Herland
, and then reset it to refs/heads/s:refs/remotes/local/s AFTER we have fetched (but before we test --track). Signed-off-by: Johan Herland jo...@herland.net --- t/t3200-branch.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh index 44ec6a4..8f6ab8e

[PATCH 3/5] Refer to branch.name.remote/merge when documenting --track

2013-09-06 Thread Johan Herland
Make it easier for readers to find the actual config variables that implement the upstream relationship. Suggested-by: Per Cederqvist ced...@opera.com Signed-off-by: Johan Herland jo...@herland.net --- In a private email exchange, Per noted that it was hard for someone reading the git-branch

[PATCH 5/5] branch.c: Relax unnecessary requirement on upstream's remote ref name

2013-09-06 Thread Johan Herland
patch to succeed, and has no negative effect on the rest of the test suite. This patch fixes a behavior (arguably a regression) first introduced in 41c21f2 (branch.c: Validate tracking branches with refspecs instead of refs/remotes/*) on 2013-04-21 (released in = v1.8.3.2). Signed-off-by: Johan

[PATCH 4/5] t3200: Add test demonstrating minor regression in 41c21f2

2013-09-06 Thread Johan Herland
through a scheduler (c) to a slave repo (d), that then tries create a local branch with an upstream. See the next patch in this series for the exciting conclusion to this story... Reported-by: Per Cederqvist ced...@opera.com Signed-off-by: Johan Herland jo...@herland.net --- I was not sure where

[PATCH 1/5] t2024: Fix inconsequential typos

2013-09-06 Thread Johan Herland
Signed-off-by: Johan Herland jo...@herland.net --- t/t2024-checkout-dwim.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh index dee55e4..6c78fba 100755 --- a/t/t2024-checkout-dwim.sh +++ b/t/t2024-checkout-dwim.sh

Re: [PATCH 1/5] t2024: Fix inconsequential typos

2013-09-06 Thread Johan Herland
On Fri, Sep 6, 2013 at 7:32 PM, Junio C Hamano gits...@pobox.com wrote: Johan Herland jo...@herland.net writes: diff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh index dee55e4..6c78fba 100755 --- a/t/t2024-checkout-dwim.sh +++ b/t/t2024-checkout-dwim.sh @@ -113,9 +113,9

[PATCHv2 0/5] branch: Fix --track on a remote-tracking non-branch

2013-09-08 Thread Johan Herland
Hi, Here is the second iteration of this series. Only one change from the first iteration: The first patch now also fixes some missing -chaining noticed by Junio in t2024. ...Johan Johan Herland (4): t2024: Fix -chaining and a couple of typos t3200: Minor fix when preparing for tracking

[PATCHv2 1/5] t2024: Fix -chaining and a couple of typos

2013-09-08 Thread Johan Herland
Improved-by: Junio C Hamano gits...@pobox.com Signed-off-by: Johan Herland jo...@herland.net --- t/t2024-checkout-dwim.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh index dee55e4..094b92e 100755 --- a/t/t2024

[PATCHv2 4/5] t3200: Add test demonstrating minor regression in 41c21f2

2013-09-08 Thread Johan Herland
through a scheduler (c) to a slave repo (d), that then tries create a local branch with an upstream. See the next patch in this series for the exciting conclusion to this story... Reported-by: Per Cederqvist ced...@opera.com Signed-off-by: Johan Herland jo...@herland.net --- t/t3200-branch.sh | 34

  1   2   3   4   >