Re: [PATCH 1/2] core: use env variable instead of config var to turn on logging pack access

2013-06-09 Thread Eric Sunshine
On Sun, Jun 9, 2013 at 1:22 AM, Nguyễn Thái Ngọc Duy wrote: > 5f44324 (core: log offset pack data accesses happened - 2011-07-06) > provides a way to observe pack access patterns via a config > switch. Setting an environment variable looks more obvious than a > config var, especially when you just

Re: [PATCH 1/2] core: use env variable instead of config var to turn on logging pack access

2013-06-09 Thread Eric Sunshine
On Sun, Jun 9, 2013 at 1:22 AM, Nguyễn Thái Ngọc Duy wrote: > 5f44324 (core: log offset pack data accesses happened - 2011-07-06) > provides a way to observe pack access patterns via a config > switch. Setting an environment variable looks more obvious than a > config var, especially when you just

Re: [PATCH 2/2] git.txt: document GIT_TRACE_PACKET

2013-06-09 Thread Eric Sunshine
On Sun, Jun 9, 2013 at 1:53 AM, Nguyễn Thái Ngọc Duy wrote: > "This can help with debugging object negotiation or other protocol > issues." s/"//g > Signed-off-by: Nguyễn Thái Ngọc Duy -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.k

Re: [PATCH] diff: add --ignore-blank-lines option

2013-06-09 Thread Eric Sunshine
On Sat, Jun 8, 2013 at 4:44 PM, Antoine Pelisse wrote: > The goal of the patch is to introduce the GNU diff > -B/--ignore-blank-lines as closely as possible. The short option is not > available because it's already used for "break-rewrites". > > When this option is used, git-diff will not create h

Re: [PATCH 04/45] pathspec: add copy_pathspec

2013-06-09 Thread Eric Sunshine
On Sun, Jun 9, 2013 at 2:25 AM, Nguyễn Thái Ngọc Duy wrote: > The function is made to use with free_pathspec() because a simple > struct assignment is not enough (free_pathspec wants to free "items" > pointer). I had to read this about five or six times before I could parse and understand it. Per

[RFH/PATCH 0/4] git http tests with apache 2.4

2013-06-09 Thread Jeff King
Apache 2.4 recently shipped in Debian unstable, and I noticed that all of the git httpd tests stopped working. It turns out that some configuration directives have changed between 2.2 and 2.4, and the httpd server would not start at all. With this series, the tests run again (for me, at least). Th

[PATCH 1/4] t/lib-httpd/apache.conf: do not use LockFile in apache >= 2.4

2013-06-09 Thread Jeff King
The LockFile directive from earlier versions of apache has been replaced by the Mutex directive. The latter seems to give sane defaults and does not need any specific customization, so we can get away with just adding a version check to the use of LockFile. Signed-off-by: Jeff King --- t/lib-htt

[PATCH 3/4] t/lib-httpd/apache.conf: load compat access module in apache 2.4

2013-06-09 Thread Jeff King
In apache 2.4, the "Order" directive has gone away in favor of a new system in mod_authz_host. However, since we want our config file to remain compatible across multiple Apache versions, we can use mod_access_compat to keep using the older style. Signed-off-by: Jeff King --- t/lib-httpd/apache.

[PATCH 2/4] t/lib-httpd/apache.conf: load extra auth modules in apache 2.4

2013-06-09 Thread Jeff King
In apache 2.4, the "Auth*" and "Require" directives have moved into the authn_core and authz_core modules, respectively. Signed-off-by: Jeff King --- t/lib-httpd/apache.conf | 9 + 1 file changed, 9 insertions(+) diff --git a/t/lib-httpd/apache.conf b/t/lib-httpd/apache.conf index 38699

[PATCH 4/4] t/lib-httpd/apache.conf: configure an MPM module for apache 2.4

2013-06-09 Thread Jeff King
Versions of Apache before 2.4 always had a "MultiProcessing Module" (MPM) statically built in, which manages the worker threads/processes. We do not care which one, as it is largely a performance issue, and we put only a light load on the server during our testing. As of Apache 2.4, the MPM module

Re: [Administrivia] On ruby and contrib/

2013-06-09 Thread Ramkumar Ramachandra
Johannes Schindelin wrote: >> Correct. The opinions of inactive community members and >> non-contributors are less useful. > > I humbly suggest to treat other people's contribution with the same > respect you want yours' to be treated. What?! When did I disrespect other people's contributions?

Re: [PATCH 2/2] Move sequencer to builtin

2013-06-09 Thread Ramkumar Ramachandra
Jeff King wrote: > Sorry that I cannot show you the source code, but you may interested to > know that libgit2 powers: Yes, I'm well aware of these: libgit2 is LGPL, because of which these three proprietary applications have been made possible. Isn't it completely orthogonal to the discussion abo

[PATCH] Document .git/modules

2013-06-09 Thread Fredrik Gustafsson
A note in the begging of this document describe the behavior already. This patch just add where to find the repositories. Signed-off-by: Fredrik Gustafsson --- Documentation/gitrepository-layout.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/gitrepository-layout.txt b/

Re: [PATCH] Document .git/modules

2013-06-09 Thread Eric Sunshine
On Sun, Jun 9, 2013 at 6:37 AM, Fredrik Gustafsson wrote: > A note in the begging of this document describe the behavior already. s/begging/beginning/ s/describe/describes/ > This patch just add where to find the repositories. s/add/adds/ > Signed-off-by: Fredrik Gustafsson -- To unsubscribe

Re: [PATCH/RFC] git-remote-mediawiki: new tool to preview local changes without pushing

2013-06-09 Thread Matthieu Moy
Jeff King writes: >> 1- Find the remote name of the current branch's upstream and check if it's a >> wiki one with its url (ie: mediawiki://) >> 2- Parse the content of the local file (given as argument) using the distant >> wiki's API. > > Makes sense. > >> 3- Retrieve the current page on the di

[PATCH] Document .git/modules

2013-06-09 Thread Fredrik Gustafsson
A note in the beginning of this document describes the behavior already. This patch just adds where to find the repositories. Signed-off-by: Fredrik Gustafsson --- Documentation/gitrepository-layout.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/gitrepository-layout.txt

Re: [PATCH] Document .git/modules

2013-06-09 Thread Fredrik Gustafsson
On Sun, Jun 09, 2013 at 06:59:17AM -0400, Eric Sunshine wrote: > On Sun, Jun 9, 2013 at 6:37 AM, Fredrik Gustafsson wrote: > > A note in the begging of this document describe the behavior already. > > s/begging/beginning/ > s/describe/describes/ > > > This patch just add where to find the reposi

Re: [PATCH 2/2] Move sequencer to builtin

2013-06-09 Thread Felipe Contreras
On Sat, Jun 8, 2013 at 11:34 PM, Jeff King wrote: > On Sat, Jun 08, 2013 at 09:20:54AM -0500, Felipe Contreras wrote: > >> Let the code speak. Show me a script in any language that does >> something useful using libgit2, doing the equivalent to at least a >> couple of 'git foo' commands. > > Sorry

Re: [PATCH 2/2] Move sequencer to builtin

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 12:26 AM, Jeff King wrote: > On Sat, Jun 08, 2013 at 09:17:56PM -0500, Felipe Contreras wrote: > >> > Definitely, yes. Even if you look at the impact on code alone and >> > don't care about the people, destroying a collegial work environment >> > is harmful enough to the co

Re: [PATCH/RFC] git-remote-mediawiki: new tool to preview local changes without pushing

2013-06-09 Thread Benoît Person
Matthieu Moy writes: > Same question here. I'd expect "git mw preview" in a mediawiki workflow > to do what "pdflatex foo && evince foo.pdf" do in a latex workflow: see > in rendered form what I've been doing. > > In a latex flow, if I want to see how my local changes merge with the > remote ones,

Re: [PATCH/RFC] git-remote-mediawiki: new tool to preview local changes without pushing

2013-06-09 Thread Benoît Person
On 9 June 2013 08:08, Jeff King wrote: > I also wonder if it would be useful to be able to specify not only files > in the filesystem, but also arbitrary blobs. So in 4b above, you could > "git mw preview origin:page.mw" to see the rendered version of what > upstream has done. Hum, so `git mw pre

Re: git-daemon: needs /root/.config/git/config?

2013-06-09 Thread Bernhard R. Link
* Ian Kumlien [130605 13:31]: > Yes, i agree, it's suboptimal but I for one would use getpwuid to get > the home directory of the executing user to avoid this - though i don't > know how portable it is (or if there is any other issues) It's not only suboptimal but simply wrong. getpwuid gives at

Re: [PATCH 2/2] Move sequencer to builtin

2013-06-09 Thread Ramkumar Ramachandra
Jeff King wrote: >> > Definitely, yes. Even if you look at the impact on code alone and >> > don't care about the people, destroying a collegial work environment >> > is harmful enough to the code to outweigh the (admittedly often >> > useful) patches. >> >> A collegial work environment is overrat

Re: [PATCH 2/2] Move sequencer to builtin

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 7:48 AM, Ramkumar Ramachandra wrote: > Jeff King wrote: >>> > Definitely, yes. Even if you look at the impact on code alone and >>> > don't care about the people, destroying a collegial work environment >>> > is harmful enough to the code to outweigh the (admittedly often >

Re: [PATCH/RFC] git-remote-mediawiki: new tool to preview local changes without pushing

2013-06-09 Thread Matthieu Moy
Benoît Person writes: > On 9 June 2013 08:08, Jeff King wrote: >> I also wonder if it would be useful to be able to specify not only files >> in the filesystem, but also arbitrary blobs. So in 4b above, you could >> "git mw preview origin:page.mw" to see the rendered version of what >> upstream

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Ramkumar Ramachandra
Felipe Contreras wrote: > The plan is simple; make libgit.a a proper library, starting by > clarifying what goes into libgit.a, and what doesn't. If there's any > hopes of ever having a public library, it's clear what code doesn't > belong in libgit.a; code that is meant for builtins, that code bel

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread John Keeping
On Sun, Jun 09, 2013 at 08:26:32PM +0530, Ramkumar Ramachandra wrote: > Felipe Contreras wrote: > > The plan is simple; make libgit.a a proper library, starting by > > clarifying what goes into libgit.a, and what doesn't. If there's any > > hopes of ever having a public library, it's clear what cod

Re: [PATCH v3 5/9] sequencer: run post-rewrite hook

2013-06-09 Thread Felipe Contreras
On Thu, Jun 6, 2013 at 1:40 PM, Junio C Hamano wrote: > It probably is worth inserting a commit before 4/9 that adds > rewrite.[ch], and > > - introduces "struct rewritten_list[_item]"; > > - moves run_rewrite_hook() in builtin/commit.c to rewrite.c; > > - changes its function signature so tha

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 10:12 AM, John Keeping wrote: > On Sun, Jun 09, 2013 at 08:26:32PM +0530, Ramkumar Ramachandra wrote: >> Felipe Contreras wrote: >> > The plan is simple; make libgit.a a proper library, starting by >> > clarifying what goes into libgit.a, and what doesn't. If there's any >>

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 9:56 AM, Ramkumar Ramachandra wrote: > Felipe Contreras wrote: >> The plan is simple; make libgit.a a proper library, starting by >> clarifying what goes into libgit.a, and what doesn't. If there's any >> hopes of ever having a public library, it's clear what code doesn't >>

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread John Keeping
On Sun, Jun 09, 2013 at 10:40:32AM -0500, Felipe Contreras wrote: > On Sun, Jun 9, 2013 at 10:12 AM, John Keeping wrote: > > On Sun, Jun 09, 2013 at 08:26:32PM +0530, Ramkumar Ramachandra wrote: > >> Felipe Contreras wrote: > >> > The plan is simple; make libgit.a a proper library, starting by > >

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 11:02 AM, John Keeping wrote: > On Sun, Jun 09, 2013 at 10:40:32AM -0500, Felipe Contreras wrote: >> On Sun, Jun 9, 2013 at 10:12 AM, John Keeping wrote: >> > On Sun, Jun 09, 2013 at 08:26:32PM +0530, Ramkumar Ramachandra wrote: >> >> Felipe Contreras wrote: >> >> > The pla

[PATCH] submodule: remove redundant check for the_index.initialized

2013-06-09 Thread René Scharfe
read_cache already performs the same check and returns immediately if the cache has already been loaded. Signed-off-by: René Scharfe --- submodule.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/submodule.c b/submodule.c index e728025..1821a5b 100644 --- a/submodule.c

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Ramkumar Ramachandra
John Keeping wrote: > How is it only useful for builtin commands? By that logic everything > belongs in builtin/ because it's all only used by builtin commands (I > realise that is what you're arguing towards). sequencer.c is merely a common API for builtins to invoke "continuations": i.e. stop t

[PATCH v4 00/45] Massive improvents to rebase and cherry-pick

2013-06-09 Thread Felipe Contreras
Hi, These are improvements to 'git rebase' by using a much improved 'git cherry-pick'. I already sent some of these, but they have been revamped. These changes require reorganization of the code in order to have a builtin/lib.a library. A new builtin/rewrite.c helper is added, and builtin/commit

[PATCH v4 10/45] sequencer: trivial fix

2013-06-09 Thread Felipe Contreras
We should free objects before leaving. Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index b2c8c94..23b01b7 100644 --- a/builtin/sequencer.c +++ b/builtin/sequencer.c @@

[PATCH v4 04/45] build: add builtin lib

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- Makefile | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 3b6cd5a..d2af207 100644 --- a/Makefile +++ b/Makefile @@ -631,6 +631,7 @@ export PERL_PATH export PYTHON_PATH LIB_FILE = libgit.a +BUILTIN_LIB

[PATCH v4 07/45] unpack-trees: plug a memory leak

2013-06-09 Thread Felipe Contreras
Before overwriting the destination index, first let's discard its contents. Signed-off-by: Felipe Contreras --- unpack-trees.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/unpack-trees.c b/unpack-trees.c index 57b4074..abe2576 100644 --- a/unpack-trees.c +++ b/unpack-tr

[PATCH v4 11/45] cherry-pick: don't barf when there's nothing to do

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 4 ++-- t/t3510-cherry-pick-sequence.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index 23b01b7..4d7dc8b 100644 --- a/builtin/sequencer.c +++ b/builtin/sequ

[PATCH v4 12/45] cherry-pick: add --skip-empty option

2013-06-09 Thread Felipe Contreras
Pretty much what it says on the tin. Signed-off-by: Felipe Contreras --- Documentation/git-cherry-pick.txt | 3 +++ builtin/revert.c| 8 builtin/sequencer.c | 6 ++ builtin/sequencer.h | 1 + t/t3508-cherry-pick-many-commits.

[PATCH v4 09/45] sequencer: remove useless indentation

2013-06-09 Thread Felipe Contreras
By using good ol' goto. Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index e92e039..b2c8c94 100644 --- a/builtin/sequencer.c +++ b/builtin/sequencer.c @@ -390,7 +39

[PATCH v4 08/45] read-cache: plug a few leaks

2013-06-09 Thread Felipe Contreras
We are not freeing 'istate->cache' properly. We can't rely on 'initialized' to keep track of the 'istate->cache', because it doesn't really mean it's initialized. So assume it always has data, and free it before overwriting it. Signed-off-by: Felipe Contreras --- read-cache.c | 4 1 file c

[PATCH v4 03/45] build: trivial cleanup

2013-06-09 Thread Felipe Contreras
There's no need to list again the prerequisites. Signed-off-by: Felipe Contreras --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 34f1240..3b6cd5a 100644 --- a/Makefile +++ b/Makefile @@ -2068,13 +2068,13 @@ $(REMOTE_CURL_PRIMARY):

[PATCH v4 01/45] build: generate and clean test scripts

2013-06-09 Thread Felipe Contreras
Commit 416fda6 (build: do not install git-remote-testpy) made it so git-remote-testpy is not only not installed, but also not generated by default, let's make sure tests scripts (NO_INSTALL) are generated as ell. Comments-by: Junio C Hamano Signed-off-by: Felipe Contreras --- Makefile | 3 ++-

[PATCH v4 14/45] revert/cherry-pick: add --skip option

2013-06-09 Thread Felipe Contreras
Akin to 'am --skip' and 'rebase --skip'. Signed-off-by: Felipe Contreras --- Documentation/git-cherry-pick.txt | 1 + Documentation/git-revert.txt | 1 + Documentation/sequencer.txt | 3 +++ builtin/revert.c | 6 ++ builtin/sequencer.c | 24 +

[PATCH v4 15/45] builtin: add rewrite helper

2013-06-09 Thread Felipe Contreras
So that we can load and store rewrites, as well as other operations on a list of rewritten commits. Signed-off-by: Felipe Contreras --- Makefile | 1 + builtin/rewrite.c | 74 +++ builtin/rewrite.h | 18 ++ 3 files changed

[PATCH v4 35/45] rebase: remove merge mode

2013-06-09 Thread Felipe Contreras
The cherrypick mode does the job. Signed-off-by: Felipe Contreras --- Makefile | 1 - contrib/completion/git-prompt.sh | 4 +- git-rebase--merge.sh | 151 --- git-rebase.sh| 13 +--- t/t3406-rebase-m

[PATCH v4 22/45] cherry-pick: remember rerere-autoupdate

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 8 1 file changed, 8 insertions(+) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index a419387..ddd369f 100644 --- a/builtin/sequencer.c +++ b/builtin/sequencer.c @@ -753,6 +753,8 @@ static int populate_opts_cb(const cha

[PATCH v4 17/45] cherry-pick: don't store skipped commit

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index 24034f2..d40fda9 100644 --- a/builtin/sequencer.c +++ b/builtin/sequencer.c @@ -953,7 +953,7 @@ static int continue_s

[PATCH v4 30/45] rebase: cherry-pick: set correct action-name

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index 241cda7..d36b0dc 100644 --- a/git-rebase--cherrypick.sh +++ b/git-rebase--cherrypick.sh @@ -45,7 +45,7 @@ e

[PATCH v4 23/45] rebase: split the cherry-pick stuff

2013-06-09 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--cherrypick.sh | 30 +++

[PATCH v4 26/45] rebase: cherry-pick: fix abort of cherry mode

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/git-rebase.sh b/git-rebase.sh index 4465daf..0937e2c 100755 --- a/git-rebase.sh +++ b/git-rebase.sh @@ -369,6 +369,7 @@ skip) run_specific_rebase ;; abort) + test "$type" =

[PATCH v4 21/45] cherry-pick: add --action-name option

2013-06-09 Thread Felipe Contreras
So it can be used by other tools (e.g. git rebase), and the right action is passed to the hooks and notes rewrite stuff. Signed-off-by: Felipe Contreras --- builtin/revert.c | 2 ++ builtin/sequencer.c| 17 ++--- builtin/sequencer.h| 2 ++ git-rebase--inte

[PATCH v4 13/45] revert/cherry-pick: add --quiet option

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- Documentation/git-cherry-pick.txt | 6 +- Documentation/git-revert.txt | 6 +- builtin/revert.c | 1 + builtin/sequencer.c | 3 +++ builtin/sequencer.h | 1 + 5 files changed, 15 insertions(+), 2 deletio

[PATCH v4 29/45] rebase: cherry-pick: automatically commit stage

2013-06-09 Thread Felipe Contreras
When there's changes in the staging area. Just like the other rebase modes. Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 6 ++ 1 file changed, 6 insertions(+) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index be17ec4..241cda7 100644 --- a/git-rebase

[PATCH v4 33/45] rebase: cherry-pick: fix for shell prompt

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- contrib/completion/git-prompt.sh | 2 ++ git-rebase--cherrypick.sh| 11 +-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/contrib/completion/git-prompt.sh b/contrib/completion/git-prompt.sh index 3a14665..3d10f21 100644 --- a/

[PATCH v4 19/45] builtin: add copy_rewrite_notes()

2013-06-09 Thread Felipe Contreras
And use it on commit.c. Signed-off-by: Felipe Contreras --- builtin/commit.c | 8 +--- builtin/rewrite.c | 17 + builtin/rewrite.h | 1 + 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/builtin/commit.c b/builtin/commit.c index 56dab4f..4f35794 100644 --- a

[PATCH v4 16/45] cherry-pick: store rewritten commits

2013-06-09 Thread Felipe Contreras
Will be useful for the next commits. Signed-off-by: Felipe Contreras --- builtin/sequencer.c | 23 ++- builtin/sequencer.h | 1 + 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/builtin/sequencer.c b/builtin/sequencer.c index 2b1b30a..24034f2 100644 --- a/buil

[PATCH v4 34/45] rebase: cherry-pick: add merge options

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 8 1 file changed, 8 insertions(+) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index 6f63618..644d45e 100644 --- a/git-rebase--cherrypick.sh +++ b/git-rebase--cherrypick.sh @@ -48,6 +48,14 @@ else fi

Re: [PATCH] submodule: remove redundant check for the_index.initialized

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 11:33 AM, René Scharfe wrote: > read_cache already performs the same check and returns immediately if > the cache has already been loaded. This time I beat you to it first ;) http://article.gmane.org/gmane.comp.version-control.git/226701 -- Felipe Contreras -- To unsubscr

[PATCH v4 24/45] rebase: cherry-pick: fix mode storage

2013-06-09 Thread Felipe Contreras
We don't use the 'rebase-apply'. Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 5 - git-rebase.sh | 5 - 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index 2c16995..e142cfb 100644 --- a/

[PATCH v4 28/45] rebase: cherry-pick: fix status messages

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index e9e..be17ec4 100644 --- a/git-rebase--cherrypick.sh +++ b/git-rebase--cherrypick.sh @@ -3,6 +3,9 @@ # Copyright (c)

[PATCH v4 20/45] cherry-pick: copy notes and run hooks

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- builtin/rewrite.c | 1 + builtin/sequencer.c | 18 +- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/builtin/rewrite.c b/builtin/rewrite.c index 02e0ea9..acbad44 100644 --- a/builtin/rewrite.c +++ b/builtin/rewrite.c @@ -1,6 +

[PATCH v4 37/45] tests: fix autostash

2013-06-09 Thread Felipe Contreras
We should call 'git rebase --abort', like a normal user would do. Signed-off-by: Felipe Contreras --- t/t3420-rebase-autostash.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/t/t3420-rebase-autostash.sh b/t/t3420-rebase-autostash.sh index a5e69f3..ff370a3 100755 --- a/t/

[PATCH v4 31/45] rebase: trivial cleanup

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- git-rebase--am.sh | 1 + git-rebase.sh | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/git-rebase--am.sh b/git-rebase--am.sh index 6460028..2ce7570 100644 --- a/git-rebase--am.sh +++ b/git-rebase--am.sh @@ -51,6 +51,7 @@ then ret

[PATCH v4 41/45] add tests for rebasing root

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano --- t/t3421-rebase-topology-linear.sh | 129 ++ 1 file changed, 129 insertions(+) diff --git a/t/t3421-rebase-topology-linear.sh b/t/t3421-rebase-topology-linear

[PATCH v4 38/45] add simple tests of consistency across rebase types

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Helped-by: Johannes Sixt Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano --- t/lib-rebase.sh | 16 t/t3421-rebase-topology-linear.sh | 78 +++ 2 files changed, 94 insertions(+) creat

[PATCH v4 32/45] rebase: use 'cherrypick' mode instead of 'am'

2013-06-09 Thread Felipe Contreras
Unless any specific 'git am' options are used. Signed-off-by: Felipe Contreras --- contrib/completion/git-prompt.sh | 2 ++ git-rebase.sh | 8 t/t3407-rebase-abort.sh| 2 +- t/t3420-rebase-autostash.sh| 2 +- t/t5520-pull.sh

[PATCH v4 45/45] tests: update topology tests

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- t/t3425-rebase-topology-merges.sh | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/t/t3425-rebase-topology-merges.sh b/t/t3425-rebase-topology-merges.sh index 5400a05..96cc479 100755 --- a/t/t3425-rebase-topology-merges.sh ++

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread John Keeping
On Sun, Jun 09, 2013 at 11:22:06AM -0500, Felipe Contreras wrote: > On Sun, Jun 9, 2013 at 11:02 AM, John Keeping wrote: > > But we make a distinction between things that are specific to one > > command (especially argument parsing and user interaction) and more > > generally useful features. > >

[PATCH v4 02/45] build: do not install git-remote-testgit

2013-06-09 Thread Felipe Contreras
Signed-off-by: Felipe Contreras --- Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile b/Makefile index 51c812d..34f1240 100644 --- a/Makefile +++ b/Makefile @@ -491,6 +491,7 @@ SCRIPT_PERL += git-svn.perl SCRIPT_PYTHON += git-remote-testpy.py SCRIPT_PYTHON += git-p4.py +NO

[PATCH v4 40/45] add tests for rebasing of empty commits

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano --- t/t3401-rebase-partial.sh | 24 t/t3421-rebase-topology-linear.sh | 58 +++ 2 files changed, 58 insertions(+), 24 deletions(-) diff -

[PATCH v4 43/45] t3406: modernize style

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Update the following: - Quote 'setup' - Remove blank lines within test case body - Use test_commit instead of custom quick_one - Create branch "topic" from tag created by test_commit Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano Conflicts:

[PATCH v4 06/45] Move sequencer to builtin

2013-06-09 Thread Felipe Contreras
This code is only useful for cherry-pick and revert built-ins, nothing else, so let's make it a builtin object. The first source file that doesn't generate a git-foo builtin, but does go into the builtin library. Hopefully the first of many to clean libgit.a. Signed-off-by: Felipe Contreras ---

[PATCH v4 25/45] rebase: cherry-pick: fix sequence continuation

2013-06-09 Thread Felipe Contreras
We are not in am mode. Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index e142cfb..d8d32fe 100644 --- a/git-rebase--cherrypick.sh +++ b/git-rebase--cherr

[PATCH v4 36/45] rebase: cherry-pick: add copyright

2013-06-09 Thread Felipe Contreras
Probably enough changes to warrant that. Signed-off-by: Felipe Contreras --- git-rebase--cherrypick.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-rebase--cherrypick.sh b/git-rebase--cherrypick.sh index 644d45e..e36e104 100644 --- a/git-rebase--cherrypick.sh +++ b/git

[PATCH v4 05/45] log-tree: remove dependency from sequencer

2013-06-09 Thread Felipe Contreras
Move the relevant code from sequencer to log-tree. This code is not specific to sequencer, and this allows the sequencer to move out of libgit. Signed-off-by: Felipe Contreras --- log-tree.c | 161 +++- log-tree.h | 3 ++ sequencer.c |

[PATCH v4 42/45] add tests for rebasing merged history

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano --- t/t3400-rebase.sh | 31 + t/t3401-rebase-partial.sh | 45 --- t/t3404-rebase-interactive.sh | 10 +- t/t3409-rebase-preserve-merges.sh | 53 t/t34

[PATCH v4 27/45] rebase: cherry-pick: fix command invocations

2013-06-09 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 v4 44/45] tests: move test for rebase messages from t3400 to t3406

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk t3406 is supposed to test "messages from rebase operation", so let's move tests in t3400 that fit that description into 3406. Most of the functionality they tested, except for the messages, has now been subsumed by t3420. Signed-off-by: Martin von Zweigbergk Signed-o

[PATCH v4 39/45] add tests for rebasing with patch-equivalence present

2013-06-09 Thread Felipe Contreras
From: Martin von Zweigbergk Signed-off-by: Martin von Zweigbergk Signed-off-by: Junio C Hamano --- t/lib-rebase.sh | 17 t/t3421-rebase-topology-linear.sh | 85 +++ 2 files changed, 102 insertions(+) diff --git a/t/lib-rebase.sh b

[PATCH v4 18/45] builtin: move run_rewrite_hook() to rewrite.c

2013-06-09 Thread Felipe Contreras
And use struct rewrite. Signed-off-by: Felipe Contreras --- builtin/commit.c | 38 +- builtin/rewrite.c | 32 builtin/rewrite.h | 1 + 3 files changed, 38 insertions(+), 33 deletions(-) diff --git a/builtin/commit.c b/builti

Re: [PATCH v4 06/45] Move sequencer to builtin

2013-06-09 Thread Antoine Pelisse
On Sun, Jun 9, 2013 at 6:40 PM, Felipe Contreras wrote: > > This code is only useful for cherry-pick and revert built-ins, nothing > else, so let's make it a builtin object. > > The first source file that doesn't generate a git-foo builtin, but does > go into the builtin library. Hopefully the fir

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Ramkumar Ramachandra
John Keeping wrote: > Calling across from one builtin/*.c file to another is just as wrong as > calling into a builtin/*.c file from a top-level file but the build > system happens not to enforce the former. So libgit.a is a collection of everything that is shared between builtins? Does that corr

Re: [PATCH v4 06/45] Move sequencer to builtin

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 12:02 PM, Antoine Pelisse wrote: > On Sun, Jun 9, 2013 at 6:40 PM, Felipe Contreras > wrote: >> >> This code is only useful for cherry-pick and revert built-ins, nothing >> else, so let's make it a builtin object. >> >> The first source file that doesn't generate a git-foo

Re: [PATCH v4 06/45] Move sequencer to builtin

2013-06-09 Thread Ramkumar Ramachandra
Antoine Pelisse wrote: > I don't understand why the code doesn't belong to libgit.a, and how > it's gonna make it more "clean". I can see that it is needed only by > revert and cherry-pick, but is that the only reason ? Perhaps this will help? [1]. Join into the discussion. [1]: http://thread.gm

Re: [PATCH v4 06/45] Move sequencer to builtin

2013-06-09 Thread Antoine Pelisse
On Sun, Jun 9, 2013 at 7:07 PM, Ramkumar Ramachandra wrote: > Antoine Pelisse wrote: >> I don't understand why the code doesn't belong to libgit.a, and how >> it's gonna make it more "clean". I can see that it is needed only by >> revert and cherry-pick, but is that the only reason ? > > Perhaps t

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 12:03 PM, Ramkumar Ramachandra wrote: > John Keeping wrote: >> Calling across from one builtin/*.c file to another is just as wrong as >> calling into a builtin/*.c file from a top-level file but the build >> system happens not to enforce the former. > > So libgit.a is a col

Re: [PATCH] build: get rid of the notion of a git library

2013-06-09 Thread Ramkumar Ramachandra
Ramkumar Ramachandra wrote: > So libgit.a is a collection of everything that is shared between > builtins? That is not to say that we shouldn't share things between builtins. We can do it in builtin/lib.a, as Felipe has demonstrated here [1]. [1]: http://article.gmane.org/gmane.comp.version-contr

[PATCH 4/4] t/push-default: test pushdefault with all modes

2013-06-09 Thread Ramkumar Ramachandra
Introduce test_pushdefault_with_mode() to test that remote.pushdefault works with all the push.default modes correctly. Exercise it with all four modes to illustrate how triangular workflows work, and to guard against regressions. Signed-off-by: Ramkumar Ramachandra --- t/t5528-push-default.sh

[PATCH 0/4] Fix triangular workflows for upstream, simple

2013-06-09 Thread Ramkumar Ramachandra
Junio C Hamano wrote: > It might be a beginning of a change in the right direction (I didn't > check the codeflow), but given that the test that comes after the > one you removed is looking at branch->merge[0] and deciding what to > do, and branch.$name.merge should *never* affect anything when > r

[PATCH 2/4] push: make upstream, simple work with pushdefault

2013-06-09 Thread Ramkumar Ramachandra
rr/triangle (4d35924, 2013-04-07) introduced support for triangular workflows, but did not think through the effect of the new configuration variables in the upstream and simple modes. When remote.pushdefault or branch..pushremote is set, and push.default is set to upstream or simple, this happens

[PATCH 3/4] t/push-default: generalize test_push_{success, commit}

2013-06-09 Thread Ramkumar Ramachandra
The setup creates two bare repositories: repo1 and repo2, but test_push_commit() hard-codes checking in repo1 for the actual output. Generalize it and its caller, test_push_success(), to optionally accept a third argument to specify the name of the repository to check for actual output. We will us

[PATCH 1/4] t/push-default: remove redundant test_config lines

2013-06-09 Thread Ramkumar Ramachandra
The line test_config push.default upstream appears unnecessarily in two tests, as the final test_push_failure sets push.default before pushing anyway. Signed-off-by: Ramkumar Ramachandra --- t/t5528-push-default.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/t/t5528-push-default.sh

Re: [PATCH v4 03/45] build: trivial cleanup

2013-06-09 Thread SZEDER Gábor
On Sun, Jun 09, 2013 at 11:40:15AM -0500, Felipe Contreras wrote: > There's no need to list again the prerequisites. > > Signed-off-by: Felipe Contreras Please write more shortlog-friendly subject lines describing what the actual change is. In this case for example: "build: substitute library p

Re: [PATCH v4 10/45] sequencer: trivial fix

2013-06-09 Thread SZEDER Gábor
On Sun, Jun 09, 2013 at 11:40:22AM -0500, Felipe Contreras wrote: > We should free objects before leaving. > > Signed-off-by: Felipe Contreras A shortlog-friendlier subject could be: "sequencer: free objects before leaving". -- To unsubscribe from this list: send the line "unsubscribe git" in t

Re: [PATCH v4 10/45] sequencer: trivial fix

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 12:18 PM, SZEDER Gábor wrote: > On Sun, Jun 09, 2013 at 11:40:22AM -0500, Felipe Contreras wrote: >> We should free objects before leaving. >> >> Signed-off-by: Felipe Contreras > > A shortlog-friendlier subject could be: "sequencer: free objects > before leaving". I alrea

Re: [PATCH v4 20/45] cherry-pick: copy notes and run hooks

2013-06-09 Thread Thomas Rast
Felipe Contreras writes: > +static void finish(struct replay_opts *opts) > +{ > + if (opts->action != REPLAY_PICK) > + return; > + > + run_rewrite_hook(&rewritten, "cherry-pick"); > + copy_rewrite_notes(&rewritten, "cherry-pick"); > +} > + Ok, so I see that with the previ

Re: [PATCH v4 42/45] add tests for rebasing merged history

2013-06-09 Thread Thomas Rast
Felipe Contreras writes: > +#TODO: make order consistent across all flavors of rebase > +test_run_rebase success 'd e n o' '' > +test_run_rebase success 'd e n o' -m > +test_run_rebase success 'd n o e' -i [45/45] would seem to imply that these tests fail as of this patch. Is that correct? If

Re: [PATCH v4 20/45] cherry-pick: copy notes and run hooks

2013-06-09 Thread Felipe Contreras
On Sun, Jun 9, 2013 at 12:22 PM, Thomas Rast wrote: > Felipe Contreras writes: > >> +static void finish(struct replay_opts *opts) >> +{ >> + if (opts->action != REPLAY_PICK) >> + return; >> + >> + run_rewrite_hook(&rewritten, "cherry-pick"); >> + copy_rewrite_notes(&rewrit

  1   2   3   4   >