[PATCH v6 13/28] rebase: split the cherry-pick stuff

2013-08-29 Thread Felipe Contreras
They do something completely different from 'git am', it belongs in a different file. No functional changes. Signed-off-by: Felipe Contreras --- .gitignore| 1 + Makefile | 1 + git-rebase--am.sh | 11 +-- git-rebase--cherrypi

[PATCH v6 22/28] t: rebase-autostash: fix setup

2013-08-29 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t3420-rebase-autostash.sh | 105 ++-- 1 file changed, 52 insertions(+), 53 deletions(-) diff --git a/t/t3420-rebase-autostash.sh b/t/t3420-rebase-autostash.sh index 90eb264..c179262 100755 --- a/t/t3420-rebase

[PATCH v6 06/28] cherry-pick: store rewritten commits

2013-08-29 Thread Felipe Contreras
Will be useful for the next commits. Signed-off-by: Felipe Contreras --- sequencer.c | 22 +- sequencer.h | 1 + 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/sequencer.c b/sequencer.c index d0e65de..468fa54 100644 --- a/sequencer.c +++ b/sequencer.c

[PATCH v6 17/28] rebase: cherry-pick: fix command invocations

2013-08-29 Thread Felipe Contreras
So that all the tests pass. Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index d8d32fe..e9e 100644 --- a/git-rebase--cherrypick.sh

[PATCH v6 09/28] builtin: rewrite: add copy_rewrite_notes()

2013-08-29 Thread Felipe Contreras
And use it on commit.c. Signed-off-by: Felipe Contreras --- builtin/commit.c | 8 +--- rewrite.c| 18 ++ rewrite.h| 1 + 3 files changed, 20 insertions(+), 7 deletions(-) diff --git a/builtin/commit.c b/builtin/commit.c index 7bfe9d0..cc589d5 100644 --- a

Re: [PATCH] revision: add --except option

2013-08-30 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 1:32 AM, Junio C Hamano wrote: > Felipe Contreras writes: > >> So that it's possible to remove certain refs from the list without >> removing the objects that are referenced by other refs. >> >> For example this repository: >>

Re: [PATCH] revision: add --except option

2013-08-30 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 2:11 AM, Johannes Sixt wrote: > Am 8/30/2013 7:00, schrieb Felipe Contreras: >> So that it's possible to remove certain refs from the list without >> removing the objects that are referenced by other refs. >> >> For example this repositor

Re: [PATCH] revision: add --except option

2013-08-30 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 2:26 AM, Junio C Hamano wrote: > Pardon terseness, typo and HTML from a tablet. > > > On Aug 30, 2013 12:19 AM, "Felipe Contreras" > wrote: >> >> On Fri, Aug 30, 2013 at 1:32 AM, Junio C Hamano wrote: >> > Felipe Contrera

Re: [PATCH] revision: add --except option

2013-08-30 Thread Felipe Contreras
because it records the information at a wrong level. I think it is not 50%, it is 98%. I think one or two persons might use this secondary feature if ever, and I think waiting for that implementation will delay the feature that 98% of people would use, and maybe block it entirely. -- Felipe Contre

Re: Officially start moving to the term 'staging area'

2013-08-30 Thread Felipe Contreras
On Thu, Aug 29, 2013 at 2:57 PM, Felipe Contreras wrote: > Again, *everyone* has agreed that index needs to be renamed, and > "staging area" is the best option. > > Do I really need to go through all the discussions and list each and > every person that participated in

Re: Officially start moving to the term 'staging area'

2013-08-30 Thread Felipe Contreras
On Thu, Aug 29, 2013 at 2:57 PM, Felipe Contreras wrote: > On Thu, Aug 29, 2013 at 1:37 PM, Junio C Hamano wrote: >> IIRC, when this was discussed, many non-native speakers had trouble >> with the verb "to stage", not just from i18n/l10n point of view. > &g

Re: Officially start moving to the term 'staging area'

2013-08-30 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 2:11 PM, Felipe Contreras wrote: > On Thu, Aug 29, 2013 at 2:57 PM, Felipe Contreras > wrote: >> Here are the threads once again: >> >> http://thread.gmane.org/gmane.comp.version-control.git/197111 >> http://thread.gmane.org/gmane.comp.vers

Re: Officially start moving to the term 'staging area'

2013-08-30 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 3:40 PM, Felipe Contreras wrote: > On Fri, Aug 30, 2013 at 2:11 PM, Felipe Contreras > wrote: >> On Thu, Aug 29, 2013 at 2:57 PM, Felipe Contreras >> wrote: > >>> Here are the threads once again: >>> >>> http://thread

[PATCH 6/6] pull: trivial cleanup

2013-08-30 Thread Felipe Contreras
There's no need to remove 'refs/heads/' yet again. Signed-off-by: Felipe Contreras --- git-pull.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/git-pull.sh b/git-pull.sh index f0df41c..3bdcbfd 100755 --- a/git-pull.sh +++ b/git-pull.sh @

[PATCH 0/6] Trivial cleanups and fixes

2013-08-30 Thread Felipe Contreras
Felipe Contreras (6): reset: trivial refactoring branch: trivial style fix rebase: trivial style fixes reset: trivial style cleanup add: trivial style cleanup pull: trivial cleanup branch.c| 2 +- builtin/add.c | 10 +- builtin/reset.c | 11 --- git-pull.sh

[PATCH 3/6] rebase: trivial style fixes

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-rebase.sh b/git-rebase.sh index 8d7659a..2c02853 100755 --- a/git-rebase.sh +++ b/git-rebase.sh @@ -324,7 +324,7 @@ done test $# -gt 2 && usage if test

[PATCH 2/6] branch: trivial style fix

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- branch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/branch.c b/branch.c index c5c6984..546c4b4 100644 --- a/branch.c +++ b/branch.c @@ -307,7 +307,7 @@ void create_branch(const char *head, start_name

[PATCH 4/6] reset: trivial style cleanup

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/reset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/reset.c b/builtin/reset.c index 225e3f1..7e65934 100644 --- a/builtin/reset.c +++ b/builtin/reset.c @@ -323,7 +323,7 @@ int cmd_reset(int argc, const char **argv, const

[PATCH 1/6] reset: trivial refactoring

2013-08-30 Thread Felipe Contreras
After commit 3fde386 (reset [--mixed]: use diff-based reset whether or not pathspec was given), some code can be moved to the 'reset_type == MIXED' check. Let's move the code that is specific to MIXED. Signed-off-by: Felipe Contreras --- builtin/reset.c | 9 +++-- 1

[PATCH 5/6] add: trivial style cleanup

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/add.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/builtin/add.c b/builtin/add.c index 8266a9c..a1e1e0e 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -336,7 +336,7 @@ static int edit_patch(int argc, const char

[PATCH 0/2] branch: improve verbose option

2013-08-30 Thread Felipe Contreras
ld be easy to revert if needed. Felipe Contreras (2): branch: trivial cleanup branch: reorganize verbose options builtin/branch.c | 33 +++-- t/t6040-tracking-info.sh | 8 2 files changed, 19 insertions(+), 22 deletions(-) -- 1.8.4-fc -- To un

[PATCH 1/2] branch: trivial cleanup

2013-08-30 Thread Felipe Contreras
No functional changes. Signed-off-by: Felipe Contreras --- builtin/branch.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/builtin/branch.c b/builtin/branch.c index 0836890..ac17b18 100644 --- a/builtin/branch.c +++ b/builtin/branch.c @@ -425,16 +425,15

[PATCH 2/2] branch: reorganize verbose options

2013-08-30 Thread Felipe Contreras
Showing the upstream tracking branch is more important than how many commits are ahead/behind, so now 'git branch -v' shows the upstream, but not the tracking info, and 'git branch -vv' shows all information (as before). Signed-off-by: Felipe Contreras --- builtin/b

Re: [PATCH] remote-hg: skip ill-formed references

2013-08-30 Thread Felipe Contreras
ot True in [c in name for c in '~^: \\'] if not ref_is_valid(tag): continue print "? refs/tags/%s" % tag -- Felipe Contreras -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.

[PATCH 0/4] t: branch: fixes and cleanups

2013-08-30 Thread Felipe Contreras
Felipe Contreras (4): t: branch: trivial style fix t: branch: fix typo t: branch: fix broken && chains t: branch: improve test rollback t/t3200-branch.sh | 82 +++ 1 file changed, 41 insertions(+), 41 deletions(-) -- 1.8.4-f

[PATCH 2/4] t: branch: fix typo

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t3200-branch.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh index ea548f9..3134652 100755 --- a/t/t3200-branch.sh +++ b/t/t3200-branch.sh @@ -351,7 +351,7 @@ test_expect_success 'test overr

[PATCH 1/4] t: branch: trivial style fix

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- 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..ea548f9 100755 --- a/t/t3200-branch.sh +++ b/t/t3200-branch.sh @@ -14,7 +14,8 @@ test_expect_success 'prepare a tr

[PATCH 3/4] t: branch: fix broken && chains

2013-08-30 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t3200-branch.sh | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh index 3134652..d85306f 100755 --- a/t/t3200-branch.sh +++ b/t/t3200-branch.sh @@ -425,14 +425,14 @@ test_expect_success '

[PATCH 4/4] t: branch: improve test rollback

2013-08-30 Thread Felipe Contreras
After every test the environment should be as close as to how it was before as possible. Signed-off-by: Felipe Contreras --- t/t3200-branch.sh | 71 +++ 1 file changed, 35 insertions(+), 36 deletions(-) diff --git a/t/t3200-branch.sh b/t

Re: Officially start moving to the term 'staging area'

2013-08-31 Thread Felipe Contreras
On Sat, Aug 31, 2013 at 2:46 AM, René Scharfe wrote: > Am 29.08.2013 22:36, schrieb Felipe Contreras: >> >> On Thu, Aug 29, 2013 at 3:03 PM, René Scharfe wrote: >>> >>> If you have a --work-tree option then parseopt accepts --work as well, >>> unless

Re: [PATCH 6/6] pull: trivial cleanup

2013-08-31 Thread Felipe Contreras
On Fri, Aug 30, 2013 at 10:58 PM, Junio C Hamano wrote: > Felipe Contreras writes: > >> There's no need to remove 'refs/heads/' yet again. >> >> Signed-off-by: Felipe Contreras >> --- >> git-pull.sh | 3 +-- >> 1 file changed, 1 insertio

Re: [PATCH] branch: use $curr_branch_short more

2013-08-31 Thread Felipe Contreras
to read more about the patch or not. -- Felipe Contreras -- 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] branch: use $curr_branch_short more

2013-08-31 Thread Felipe Contreras
rhaps it should be. > I felt that using something that's already there instead of recreating it is > motivation alone. Why? Because it simplifies the code. That's the real answer. -- Felipe Contreras -- 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] branch: use $curr_branch_short more

2013-08-31 Thread Felipe Contreras
On Sat, Aug 31, 2013 at 5:28 AM, René Scharfe wrote: > Am 31.08.2013 11:22, schrieb Felipe Contreras: > >> On Sat, Aug 31, 2013 at 4:11 AM, René Scharfe wrote: >> >>>> Subject: pull: trivial simplification >>>> >>>> With that summary, peop

Re: [PATCH 0/2] branch: improve verbose option

2013-08-31 Thread Felipe Contreras
On Sat, Aug 31, 2013 at 9:41 AM, Philip Oakley wrote: > From: "Felipe Contreras" >>Showing ahead/behind is >> not as important, > > > I still find this useful - if it's up to date I don't need reminding of > which remote / upstream tracking

Re: [PATCH] remote-hg: skip ill-formed references

2013-08-31 Thread Felipe Contreras
On Sat, Aug 31, 2013 at 8:58 AM, Max Kirillov wrote: > Felipe Contreras > gmail.com> writes: >> Which repository triggered this? > > Tha was some of the vim repositories, upstream > https://code.google.com/p/vim/ or debian > anonscm.debian.org/hg/pkg-vim/vim, or bot

Re: [PATCH] remote-hg: skip ill-formed references

2013-08-31 Thread Felipe Contreras
On Sat, Aug 31, 2013 at 8:58 AM, Max Kirillov wrote: > Felipe Contreras > gmail.com> writes: >> Which repository triggered this? > > Tha was some of the vim repositories, upstream > https://code.google.com/p/vim/ or debian > anonscm.debian.org/hg/pkg-vim/vim, or bot

Re: [PATCH] revision: add --except option

2013-08-31 Thread Felipe Contreras
ce = &revs->cmdline.rev[i]; if ((ce->flags & SKIP) && !refcmp(ce->name, e->name)) goto next; } + commit = handle_commit(revs, e->item, e->name); if (commit) { if (!(commit->object.flags & SEEN)) { commit->object.flags |= SEEN; -- Felipe Contreras -- 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] revision: introduce --exclude= to tame wildcards

2013-08-31 Thread Felipe Contreras
the trick with: --branches --except --glob='heads/??/*' -- Felipe Contreras -- 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 v2] revision: add --except option

2013-08-31 Thread Felipe Contreras
ing '--branches --not crap' nothing will come out. Signed-off-by: Felipe Contreras --- I don't like the complexity of recalculate_flag(), but it seems to be the most straight-forward way of making --not and --except work. Documentation/git-rev-parse.txt| 6 contrib/compl

[PATCH 0/3] Reject non-ff pulls by default

2013-08-31 Thread Felipe Contreras
Junio already sent a similar patch, but I think this is simpler. Felipe Contreras (3): merge: simplify ff-only option t: replace pulls with merges pull: reject non-ff pulls by default Documentation/git-pull.txt | 1 + builtin/merge.c| 20

[PATCH 1/3] merge: simplify ff-only option

2013-08-31 Thread Felipe Contreras
No functional changes. Signed-off-by: Felipe Contreras --- builtin/merge.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/builtin/merge.c b/builtin/merge.c index 34a6166..da9fc08 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -186,13 +186,6 @@ static int

[PATCH 3/3] pull: reject non-ff pulls by default

2013-08-31 Thread Felipe Contreras
For the full discussion: http://thread.gmane.org/gmane.comp.version-control.git/225146/focus=225305 The user still can specify 'git pull --merge' to restore the old behavior, or 'git config pull.rebase false'. Signed-off-by: Felipe Contreras --- Documentation/git-pull.tx

[PATCH 2/3] t: replace pulls with merges

2013-08-31 Thread Felipe Contreras
This is what the code intended. No functional changes. Signed-off-by: Felipe Contreras --- t/annotate-tests.sh| 2 +- t/t4200-rerere.sh | 2 +- t/t9114-git-svn-dcommit-merge.sh | 2 +- t/t9500-gitweb-standalone-no-errors.sh | 2 +- 4 files changed

[PATCH 2/2] fast-export: refactor get_tags_and_duplicates()

2013-09-01 Thread Felipe Contreras
Split into a separate helper function get_commit() so that the part that finds the relevant commit, and the part that does something with it (handle tag object, etc.) are in different places. No functional changes. Signed-off-by: Felipe Contreras --- builtin/fast-export.c | 68

[PATCH 0/2] fast-export: simplification

2013-09-01 Thread Felipe Contreras
Hi, No functional changes, but get_tags_and_duplicates() is quite complex as it is, and can be simplified by spliting code into a separate function. Felipe Contreras (2): fast-export: make extra_refs global fast-export: refactor get_tags_and_duplicates() builtin/fast-export.c | 87

[PATCH 1/2] fast-export: make extra_refs global

2013-09-01 Thread Felipe Contreras
There's no need to pass it around everywhere. This would make easier further refactoring that makes use of this variable. Signed-off-by: Felipe Contreras --- builtin/fast-export.c | 21 ++--- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/builtin/fast-expor

[PATCH 4/6] t: branch add publish branch tests

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t3200-branch.sh | 76 +++ 1 file changed, 76 insertions(+) diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh index 44ec6a4..cd0b8e9 100755 --- a/t/t3200-branch.sh +++ b/t/t3200-branch.sh @@ -870,4 +870,80

[PATCH 6/6] branch: display publish branch

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/branch.c | 45 - 1 file changed, 40 insertions(+), 5 deletions(-) diff --git a/builtin/branch.c b/builtin/branch.c index 48af999..47644ad 100644 --- a/builtin/branch.c +++ b/builtin/branch.c @@ -42,6 +42,7

[PATCH 1/6] push: trivial reorganization

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/push.c | 35 +++ 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/builtin/push.c b/builtin/push.c index 04f0eaf..5dc06a3 100644 --- a/builtin/push.c +++ b/builtin/push.c @@ -113,20 +113,11 @@ static

[PATCH 5/6] push: add --set-publish option

2013-09-01 Thread Felipe Contreras
To setup publish tracking branch, like 'git branch --set-publish'. Signed-off-by: Felipe Contreras --- Documentation/git-push.txt | 9 +- builtin/push.c | 2 ++ t/t5529-push-publish.sh| 70 ++ transport.c

[PATCH 0/6] Introduce publish tracking branch

2013-09-01 Thread Felipe Contreras
/fast 177dcad [master, gh/fc/branch/fast] branch: reorganize verbose options fc/trivial f289b9a [master: ahead 7] branch: trivial style fix fc/leaksd101af4 [master: ahead 2] read-cache: plug a possible leak stable e230c56 Git 1.8.4 Felipe Contreras (6): push: tr

[PATCH 2/6] Add concept of 'publish' branch

2013-09-01 Thread Felipe Contreras
The upstream branch is: branch.$name.remote branch.$name.merge The publish branch is: branch.$name.pushremote branch.$name.push Signed-off-by: Felipe Contreras --- builtin/push.c | 19 +++ remote.c | 34 -- remote.h | 4

[PATCH 3/6] branch: allow configuring the publish branch

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- Documentation/git-branch.txt | 11 + branch.c | 43 ++ branch.h | 2 ++ builtin/branch.c | 56 4 files changed, 108

Re: [PATCH 2/6] Add concept of 'publish' branch

2013-09-01 Thread Felipe Contreras
On Sun, Sep 1, 2013 at 3:41 AM, Eric Sunshine wrote: > On Sun, Sep 1, 2013 at 4:26 AM, Felipe Contreras > wrote: >> +static void setup_push_simple(struct remote *remote, struct branch *branch, >> + int triangular) >> +{ >>

[PATCH 2/4] t: rev-parse-parents: fix weird ! notation

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t6101-rev-parse-parents.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t6101-rev-parse-parents.sh b/t/t6101-rev-parse-parents.sh index bead4d7..c10580c 100755 --- a/t/t6101-rev-parse-parents.sh +++ b/t/t6101-rev-parse-parents.sh

[PATCH 4/4] t: rev-parse-parents: simplify setup

2013-09-01 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t6101-rev-parse-parents.sh | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/t/t6101-rev-parse-parents.sh b/t/t6101-rev-parse-parents.sh index b9aef31..0653f5e 100755 --- a/t/t6101-rev-parse-parents.sh +++ b/t/t6101

[PATCH 3/4] t: rev-parse-parents: avoid yoda conditions

2013-09-01 Thread Felipe Contreras
Just as 5 == X is weird, so is comparing first the expected value, and then the value we are testing. So switch them around. Signed-off-by: Felipe Contreras --- t/t6101-rev-parse-parents.sh | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/t/t6101-rev-parse-parents.sh

[PATCH 0/4] t: rev-parse-parents: cleanups

2013-09-01 Thread Felipe Contreras
Felipe Contreras (4): t: rev-parse-parents: fix style t: rev-parse-parents: fix weird ! notation t: rev-parse-parents: avoid yoda conditions t: rev-parse-parents: simplify setup t/t6101-rev-parse-parents.sh | 96 +++- 1 file changed, 69 insertions

[PATCH 1/4] t: rev-parse-parents: fix style

2013-09-01 Thread Felipe Contreras
Pretty much all the tests follow a different style. Signed-off-by: Felipe Contreras --- t/t6101-rev-parse-parents.sh | 74 ++-- 1 file changed, 58 insertions(+), 16 deletions(-) diff --git a/t/t6101-rev-parse-parents.sh b/t/t6101-rev-parse-parents.sh

[PATCH v5 2/2] Add new @ shortcut for HEAD

2013-09-01 Thread Felipe Contreras
#x27;HEAD'. So now we can use 'git show @~1', and all that goody goodness. Until now '@' was a valid name, but it conflicts with this idea, so let's make it invalid. Probably very few people, if any, used this name. Signed-off-by: Felipe Contreras Signed-of

[PATCH v5 0/2] Add @ shortcut, again

2013-09-01 Thread Felipe Contreras
Felipe Contreras (2): sha1-name: pass len argument to interpret_branch_name() Add new @ shortcut for HEAD Documentation/git-check-ref-format.txt | 2 ++ Documentation/revisions.txt| 3 +++ cache.h| 2 +- refs.c

[PATCH v5 1/2] sha1-name: pass len argument to interpret_branch_name()

2013-09-01 Thread Felipe Contreras
rgument is passed. So let's do that. Signed-off-by: Felipe Contreras --- cache.h | 2 +- refs.c | 2 +- revision.c | 2 +- sha1_name.c | 10 ++ 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/cache.h b/cache.h index 85b544f..9fbc5fa 100644 --- a/cache.

Re: [PATCH] revision: add --except option

2013-09-01 Thread Felipe Contreras
On Mon, Sep 2, 2013 at 1:25 AM, Johannes Sixt wrote: > Am 8/31/2013 21:27, schrieb Felipe Contreras: >> On Fri, Aug 30, 2013 at 2:56 AM, Johannes Sixt wrote: >>> Am 8/30/2013 8:32, schrieb Junio C Hamano: >>>> If you have a history where >>>> >>>

Re: [PATCH v2] revision: add --except option

2013-09-01 Thread Felipe Contreras
dictate the behavior, because it doesn't matter if you have described perfect behavior, and the implementation is nearly impossible. If you disagree, feel free to write the code. Talk is cheap, show me the code. -- Linus Torvalds -- Felipe Contreras -- To unsubscribe from this list: send the l

[PATCH] sha1-name: refactor get_sha1() parsing

2013-09-01 Thread Felipe Contreras
Instead of parsing left to right, do it right do left, this way it is much more natural and probably efficient too, as there's less recursivity. In theory there shouldn't be any functional changes, although there's at least one error message that has changed. Signed-off-by: F

Re: [PATCH v2 2/4] transport-helper: add no-private-update capability

2013-09-02 Thread Felipe Contreras
On Mon, Sep 2, 2013 at 2:19 AM, Matthieu Moy wrote: > Since 664059fb62 (Felipe Contreras, Apr 17 2013, transport-helper: update > remote helper namespace), a 'push' operation on a remote helper updates > the private ref by default. This is often a good thing, but it can als

Re: [PATCH 0/6] Introduce publish tracking branch

2013-09-02 Thread Felipe Contreras
On Mon, Sep 2, 2013 at 2:25 AM, Matthieu Moy wrote: > Felipe Contreras writes: >> As it has been discussed before, our support for triangular workflows is >> lacking, and the following patch series aims to improve that situation. > > I may be stating the obvious, bu

[PATCH 0/6] Preparation for non-ff pulls by default

2013-09-02 Thread Felipe Contreras
l.mode = merge-ff-only. Later on this mode can be enabled by default (e.g. in v2.0). To achieve that first some configurations are renamed: for example: pull.rebase => pull.mode = rebase, but the old ones remain functional, thus there are no functional changes. Felipe Contreras (6): m

[PATCH 6/6] pull: add merge-ff-only option

2013-09-02 Thread Felipe Contreras
merge-ff-only. Later on this mode can be enabled by default (e.g. in v2.0). For the full discussion you can read: http://thread.gmane.org/gmane.comp.version-control.git/225146/focus=225305 Signed-off-by: Felipe Contreras --- Documentation/config.txt | 8 +--- builtin/merge.c

[PATCH 5/6] pull: add --merge option

2013-09-02 Thread Felipe Contreras
Also, deprecate --no-rebase since there's no need for it any more. Signed-off-by: Felipe Contreras --- Documentation/git-pull.txt | 8 ++-- git-pull.sh| 6 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Documentation/git-pull.txt b/Documentatio

[PATCH 3/6] pull: rename pull.rename to pull.mode

2013-09-02 Thread Felipe Contreras
Also 'branch..rebase' to 'branch..pullmode'. This way 'pull.mode' can be set to 'merge', and the default can be something else. The old configurations still work, but get deprecated. Signed-off-by: Felipe Contreras --- Documentation/config.txt | 22 +

[PATCH 1/6] merge: simplify ff-only option

2013-09-02 Thread Felipe Contreras
No functional changes. Signed-off-by: Felipe Contreras --- builtin/merge.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/builtin/merge.c b/builtin/merge.c index 34a6166..da9fc08 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -186,13 +186,6 @@ static int

[PATCH 4/6] pull: refactor $rebase variable into $mode

2013-09-02 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-pull.sh | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/git-pull.sh b/git-pull.sh index de57c1d..f53d193 100755 --- a/git-pull.sh +++ b/git-pull.sh @@ -48,8 +48,7 @@ if test -z "$mode" then

[PATCH 2/6] t: replace pulls with merges

2013-09-02 Thread Felipe Contreras
This is what the code intended. No functional changes. Signed-off-by: Felipe Contreras --- t/annotate-tests.sh| 2 +- t/t4200-rerere.sh | 2 +- t/t9114-git-svn-dcommit-merge.sh | 2 +- t/t9500-gitweb-standalone-no-errors.sh | 2 +- 4 files changed

Re: [PATCH] revision: introduce --exclude= to tame wildcards

2013-09-02 Thread Felipe Contreras
po-order test --not master --except master test > actual && + git rev-list --topo-order test > expect && + test_cmp expect actual +' + +test_expect_success 'rev-list multiple --not ranges' ' + + git checkout -b extra test && + echo five > content && + git commit -a -m five && + git rev-list --topo-order test --not master --except master test --not extra > actual && + git rev-list --topo-order test extra > expect && + test_cmp expect actual +' + -- Felipe Contreras -- 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 3/4] t: rev-parse-parents: avoid yoda conditions

2013-09-03 Thread Felipe Contreras
test_cmp_args () { > eval "$1" >expect && > eval "$2" >actual && I don't see any reason to perpetuate these yoda comparisons. eval "$2" >expect && eval "$1" >actual && > test_cmp expect actual > } -- Felipe Contreras -- 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 3/4] t: rev-parse-parents: avoid yoda conditions

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 6:10 AM, SZEDER Gábor wrote: > On Tue, Sep 03, 2013 at 05:45:06AM -0500, Felipe Contreras wrote: >> On Tue, Sep 3, 2013 at 3:03 AM, Jeff King wrote: >> > On Tue, Sep 03, 2013 at 09:51:07AM +0200, SZEDER Gábor wrote: >> > >>

Re: [PATCH 3/4] rev-parse test: use test_cmp instead of "test" builtin

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 12:07 PM, Jonathan Nieder wrote: > test_expect_success 'start^0' ' > - test $(cat .git/refs/tags/start) = $(git rev-parse start^0) > + test_cmp_rev_output tags/start "git rev-parse start^0" > ' Backwards and yo

Re: [PATCH 0/4] Re: [PATCH 3/4] t: rev-parse-parents: avoid yoda conditions

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 12:04 PM, Jonathan Nieder wrote: > SZEDER Gábor wrote: >> On Tue, Sep 03, 2013 at 08:39:54AM -0500, Felipe Contreras wrote: > >>> There are two ways to fix an inconsistency, the other way is to fix >>> test_cmp. But that would be a change

Re: [PATCH 3/4] t: rev-parse-parents: avoid yoda conditions

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 12:31 PM, Junio C Hamano wrote: > Felipe Contreras writes: > >> There are two ways to fix an inconsistency, the other way is to fix >> test_cmp. But that would be a change, and change is not welcome in >> Git. > > If you want to do "t

Re: [PATCH 2/4] rev-parse test: use test_must_fail, not "if ; then false; fi"

2013-09-03 Thread Felipe Contreras
> rev-parse test: use test_must_fail, not "if ; then false; fi" That is way more than 50 characters, and doesn't tell me why you want to do that. -- Felipe Contreras -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to ma

Re: [PATCH 0/3] Reject non-ff pulls by default

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 12:21 PM, Junio C Hamano wrote: > Felipe Contreras writes: > >> Junio already sent a similar patch, but I think this is simpler. > > I agree that this is simpler, but I am not sure if the behaviour is > necessarily better (note that this is different

Re: [PATCH 4/4] t: branch: improve test rollback

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 2:32 PM, Junio C Hamano wrote: > Felipe Contreras writes: >> test_expect_success 'refuse --edit-description on unborn branch for now' ' >> + test_when_finished "git checkout -" && > > I am not sure if this is

Re: [PATCH] revision: introduce --exclude= to tame wildcards

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 10:45 AM, Junio C Hamano wrote: > Felipe Contreras writes: > >> On Fri, Aug 30, 2013 at 6:55 PM, Junio C Hamano wrote: >>> People often find "git log --branches" etc. that includes _all_ >>> branches is cumbersome to use when th

Re: [PATCH 0/3] Reject non-ff pulls by default

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 5:38 PM, Junio C Hamano wrote: > Felipe Contreras writes: > >> On Tue, Sep 3, 2013 at 12:21 PM, Junio C Hamano wrote: >>> Felipe Contreras writes: >>> >>>> Junio already sent a similar patch, but I think this is simpler. >>

Re: [PATCH 4/4] t: branch: improve test rollback

2013-09-03 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 5:59 PM, Junio C Hamano wrote: > Felipe Contreras writes: > >> On Tue, Sep 3, 2013 at 2:32 PM, Junio C Hamano wrote: >>> Felipe Contreras writes: >> >>>> test_expect_success 'refuse --edit-description on unborn branch f

Re: [PATCH] GIT-VERSION-GEN: Do not require tags to be annotated

2013-09-06 Thread Felipe Contreras
ertain mistakes, then that's the way it should be? What's the point of lightweight tags anyway? 'git describe' doesn't use them, GIT-VERSION-GEN neither, just remove them already. For the vast majority of the people out there, a tag is a tag. Period. -- Felipe Contreras

Re: [PATCH] remote-bzr: reuse bzrlib transports when possible

2013-09-07 Thread Felipe Contreras
ions have > exited, causing a deadlock. (The ssh sessions are closed in an > undefined order because bzrlib relies on the Python garbage > collector to trigger ssh session termination.) Looks good to me. I'll apply in my personal repository. -- Felipe Contreras -- To un

Re: [PATCH] remote-bzr: reuse bzrlib transports when possible

2013-09-07 Thread Felipe Contreras
h session termination.) > > I forgot to mention: I didn't add a Signed-off-by line because there is > no mention of a copyright license at the top of git-remote-bzr. And why is that relevant? A signed-off-by line means you wrote the code and you are fine with the patch being applied,

Re: coming from git, understanding mercurial branching

2013-09-07 Thread Felipe Contreras
complete isolation in case you screw up something like > merging, use a clone I guess so. There's also the option of using the 'mq' extension, which I guess it's similar to quilt. -- Felipe Contreras -- 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-VERSION-GEN: Do not require tags to be annotated

2013-09-07 Thread Felipe Contreras
gt; run something like this instead? > > git describe --tags HEAD >version && make Which is a pretty stupid option. 'git describe' does use tags by default anyway, what else is it supposed to do? -- Felipe Contreras -- To unsubscribe from this list: send the lin

Re: [PATCH] GIT-VERSION-GEN: Do not require tags to be annotated

2013-09-07 Thread Felipe Contreras
On Fri, Sep 6, 2013 at 11:30 PM, David Aguilar wrote: > > On Sep 6, 2013 7:51 PM, "Felipe Contreras" > wrote: >> >> Junio C Hamano wrote: >> > Sebastian Schuberth writes: >> > >> > > For custom builds of Git it sometimes is inconvenie

Re: [PATCH] git_remote_helpers: remove little used Python library

2013-09-07 Thread Felipe Contreras
it_remote_helpers However, in the latest msysgit master it seems the git-remote-hg helper is gone, I don't know if by mistake or what. Johannes Schindelin made many claims about it being more complete and what not, but who knows what actually happened. -- Felipe Contreras -- To unsubscribe from

Re: Officially start moving to the term 'staging area'

2013-09-07 Thread Felipe Contreras
all. Instead he > writes in following way: Same goes for the ProGit book, which is quite famous: http://git-scm.com/book/en/Git-Basics-Recording-Changes-to-the-Repository http://git-scm.com/book/en/Git-Tools-Interactive-Staging -- Felipe Contreras -- To unsubscribe from this list: send the line &quo

Re: Officially start moving to the term 'staging area'

2013-09-07 Thread Felipe Contreras
need. Nobody thinks of the staging area that way, just you. The staging area is an area that contains the preparation for the next commit to be made. There's no ships, or trailers, or bundles. Everybody understands that, and find the term "staging area" fit for that description. Except you. -- Felipe Contreras -- 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: Officially start moving to the term 'staging area'

2013-09-07 Thread Felipe Contreras
s with users. > Renaming core objects is just going to sow confusion without fixing > the user communication issue. That's what I meant the first time I > wrote what I quote directly above and I'm sticking to it. The vast majority of Git users have absolutely no clue about what's the index. That's why online documentation uses the term "staging area", so in fact we would be reducing confusion, by a lot. -- Felipe Contreras -- 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: Officially start moving to the term 'staging area'

2013-09-07 Thread Felipe Contreras
On Tue, Sep 3, 2013 at 11:45 PM, Drew Northup wrote: > On Thu, Aug 29, 2013 at 6:10 PM, Felipe Contreras > wrote: >> On Thu, Aug 29, 2013 at 4:55 PM, Drew Northup wrote: >>> On Thu, Aug 29, 2013 at 2:37 PM, Junio C Hamano wrote: >>>> Felipe Contreras writes:

Re: [PATCH 0/3] Reject non-ff pulls by default

2013-09-07 Thread Felipe Contreras
patches to support the @{tail} shorthand, which is basically the point where the branch was created, or rebased to: https://github.com/felipec/git/commits/fc/base And if 'git rebase' was fixed to ignore the commits already in the rebased onto branch, almost always what you would want to

Re: [PATCH 0/3] Reject non-ff pulls by default

2013-09-07 Thread Felipe Contreras
log >> until it finds an ancestor of the current branch and uses that as the >> parameter to rebase. > > You're right. > > It makes me wonder why we did that one inside pull and not in > rebase, though. Because there's a huge difference between: git rebase @{u}@{1}

<    4   5   6   7   8   9   10   11   12   13   >