Saving space/network on common repos

2014-12-16 Thread Craig Silverstein
At Khan Academy, we are running a Jenkins installation as our build server. By design, our Jenkins machine has several different directories that each hold a copy of the same git repository. (For instance, Jenkins may be running tests on our repo at several different commits at the same time.) W

Re: hooks scripts and noexec partition

2014-12-16 Thread Jeff King
On Sun, Dec 14, 2014 at 02:44:35AM +0100, krz...@gmail.com wrote: > Thanks for the patch, however it is not working (no change, hooks > still dont work on noexec partition). Since I see that you are fluent > in git code and C can you by any chance tell me how to modify > run-command.c to make git

Re: [PATCH] Update documentation occurrences of filename .sh

2014-12-16 Thread Jonathan Nieder
Peter van der Does wrote: > Documentation in the completion scripts for Bash and Zsh state the wrong > filenames. > > Signed-off-by: Peter van der Does > --- > contrib/completion/git-completion.bash | 4 ++-- > contrib/completion/git-completion.zsh | 2 +- > 2 files changed, 3 insertions(+), 3

[PATCH] git-compat-util: suppress unavoidable Apple-specific deprecation warnings

2014-12-16 Thread Eric Sunshine
With the release of Mac OS X 10.7 in July 2011, Apple deprecated all openssl.h functionality due to OpenSSL ABI (application binary interface) instability, resulting in an explosion of compilation warnings about deprecated SSL, SHA1, and X509 functions (among others). 61067954ce (cache.h: eliminat

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Stefan Beller
On Tue, Dec 16, 2014 at 12:46 PM, Junio C Hamano wrote: > Stefan Beller writes: > >> On Tue, Dec 16, 2014 at 11:46 AM, Junio C Hamano wrote: >> >>> >>> Seeing that all callers of test_ref_upstream computes $2 as >>> >>> git -C workbench rev-parse --verify >>> >> >> Only in the first tes

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > On Tue, Dec 16, 2014 at 11:46 AM, Junio C Hamano wrote: > >> >> Seeing that all callers of test_ref_upstream computes $2 as >> >> git -C workbench rev-parse --verify >> > > Only in the first tests, where this should be the case after push. > In the failure tests,

Re: [PATCHv2 5/6] push.c: add an --atomic-push argument

2014-12-16 Thread Junio C Hamano
Eric Sunshine writes: >> +--atomic:: >> + Use the an atomic transaction on the server side if available. > > s/the an/an/ > ... >> + OPT_BIT(0, "atomic", &flags, N_("use a single atomic >> transaction at the serverside, if available"), > > "single atomic" sounds awfully redun

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Stefan Beller
On Tue, Dec 16, 2014 at 12:30 PM, Junio C Hamano wrote: > Stefan Beller writes: > >> > What's the value of this test? Isn't it a non-fast-forward check >> > you already tested in the previous one? >> >> I messed up there. Originally I wanted to test the 2 different >> stages of r

Re: [PATCH] receive-pack: refuse all commands if one fails in atomic mode

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > This patch will be incorporated into the right places in v3 of the series. > > Signed-off-by: Stefan Beller > --- > > Notes: > I don't want to resend the patch series today to accumulate comments, > but this makes the last test pass, which is the whole point of th

Re: [PATCHv2 4/6] receive-pack.c: use a single ref_transaction for atomic pushes

2014-12-16 Thread Eric Sunshine
On Tue, Dec 16, 2014 at 2:29 PM, Eric Sunshine wrote: > On Tue, Dec 16, 2014 at 1:49 PM, Stefan Beller wrote: >> --- >> diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c >> index e76e5d5..0803fd2 100644 >> --- a/builtin/receive-pack.c >> +++ b/builtin/receive-pack.c >> @@ -1059,6 +1059

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > > What's the value of this test? Isn't it a non-fast-forward check > > you already tested in the previous one? > > I messed up there. Originally I wanted to test the 2 different > stages of rejection. A non-fast-forward check is done locally and >

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Stefan Beller
On Tue, Dec 16, 2014 at 11:46 AM, Junio C Hamano wrote: > > Seeing that all callers of test_ref_upstream computes $2 as > > git -C workbench rev-parse --verify > Only in the first tests, where this should be the case after push. In the failure tests, we go with HEAD@{N} which needs to b

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > +test_description='pushing to a repository using the atomic push option' > + > +. ./test-lib.sh > + > +D=`pwd` $(pwd)? > +mk_repo_pair () { > + rm -rf workbench upstream && > + test_create_repo upstream && > + test_create_repo workbench && > + ( > +

confusion with some `git reset` commands

2014-12-16 Thread Arup Rakshit
Hi, >From the command help I see - [arup@to_do_app]$ git reset -h usage: git reset [--mixed | --soft | --hard | --merge | --keep] [-q] [] or: git reset [-q] [--] ... or: git reset --patch [] [--] [...] -q, --quiet be quiet, only report errors --mixed rese

Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Eric Sunshine
On Tue, Dec 16, 2014 at 1:49 PM, Stefan Beller wrote: > This adds tests for the atomic push option. > The first four tests check if the atomic option works in > good conditions and the last three patches check if the atomic > option prevents any change to be pushed if just one ref cannot > be upda

Re: [PATCHv2 5/6] push.c: add an --atomic-push argument

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > From: Ronnie Sahlberg > > Add a command line argument to the git push command to request atomic > pushes. > > Signed-off-by: Ronnie Sahlberg > Signed-off-by: Stefan Beller > --- > > Notes: > Changes v1 -> v2 > It's --atomic now! (dropping the -push) Also from

Re: [PATCHv2 4/6] receive-pack.c: use a single ref_transaction for atomic pushes

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > * update(...) assumes to be always in a transaction > * Caring about when to begin/commit transactions is put > into execute_commands I am obviously biased, but I find that the new code structure and separation of responsibility between update() and ex

bug & patch: exit codes from internal commands are handled incorrectly

2014-12-16 Thread Kenneth Lorber
(Apologies if I’ve missed anything here - I’m still climbing the git learning curve.) Bug: exit codes from (at least) internal commands are handled incorrectly. E.g. git-merge-file, docs say: The exit value of this program is negative on error, and the number of conflicts otherwis

Re: [PATCHv2 5/6] push.c: add an --atomic-push argument

2014-12-16 Thread Eric Sunshine
On Tue, Dec 16, 2014 at 1:49 PM, Stefan Beller wrote: > From: Ronnie Sahlberg > > Add a command line argument to the git push command to request atomic > pushes. > > Signed-off-by: Ronnie Sahlberg > Signed-off-by: Stefan Beller > --- > > Notes: > Changes v1 -> v2 > It's --atomic now

Re: [PATCHv2 3/6] send-pack.c: add --atomic command line argument

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > * Now we only need a very small change in the existing code and have >a new static function, which cares about error reporting. > Junio wrote: > > Hmph. Is "atomic push" so special that it deserves a separate > > parameter? When we co

Re: [PATCHv2 4/6] receive-pack.c: use a single ref_transaction for atomic pushes

2014-12-16 Thread Eric Sunshine
On Tue, Dec 16, 2014 at 1:49 PM, Stefan Beller wrote: > From: Ronnie Sahlberg > > Update receive-pack to use an atomic transaction iff the client negotiated > that it wanted atomic-push. This leaves the default behavior to be the old > non-atomic one ref at a time update. This is to cause as litt

[PATCH] receive-pack: refuse all commands if one fails in atomic mode

2014-12-16 Thread Stefan Beller
This patch will be incorporated into the right places in v3 of the series. Signed-off-by: Stefan Beller --- Notes: I don't want to resend the patch series today to accumulate comments, but this makes the last test pass, which is the whole point of the series. I'll put it into th

Re: [PATCHv2 2/6] send-pack: Invert the return value of ref_update_to_be_sent

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > Having the return value inverted we can have different values for > the error codes. This is useful in a later patch when we want to > know if we hit the REF_STATUS_REJECT_* case. > > Signed-off-by: Stefan Beller > --- > > Notes: > New in the series. For consistency w

Re: [PATCH 1/1] tests: make comment match the code

2014-12-16 Thread Eric Sunshine
On Tue, Dec 16, 2014 at 3:40 AM, Christian Hesse wrote: > GnuPG homedir is generated on the fly and keys are imported from > armored key file. Make commet match available key info and new key s/commet/comment/ > generation procedure. > > Signed-off-by: Christian Hesse -- To unsubscribe from thi

Re: [PATCHv2 1/6] receive-pack.c: add protocol support to negotiate atomic-push

2014-12-16 Thread Junio C Hamano
Stefan Beller writes: > diff --git a/send-pack.c b/send-pack.c > index 949cb61..2a513f4 100644 > --- a/send-pack.c > +++ b/send-pack.c > @@ -294,6 +294,8 @@ int send_pack(struct send_pack_args *args, > int use_sideband = 0; > int quiet_supported = 0; > int agent_supported = 0; >

Re: [PATCH 1/1] tests: make comment match the code

2014-12-16 Thread Junio C Hamano
Thanks. -- 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] t5400: remove dead code

2014-12-16 Thread Junio C Hamano
Thanks. -- 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

[PATCHv2 4/6] receive-pack.c: use a single ref_transaction for atomic pushes

2014-12-16 Thread Stefan Beller
From: Ronnie Sahlberg Update receive-pack to use an atomic transaction iff the client negotiated that it wanted atomic-push. This leaves the default behavior to be the old non-atomic one ref at a time update. This is to cause as little disruption as possible to existing clients. It is unknown if

[PATCHv2 2/6] send-pack: Invert the return value of ref_update_to_be_sent

2014-12-16 Thread Stefan Beller
Having the return value inverted we can have different values for the error codes. This is useful in a later patch when we want to know if we hit the REF_STATUS_REJECT_* case. Signed-off-by: Stefan Beller --- Notes: New in the series. For consistency with all the other patches it also re

[PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes

2014-12-16 Thread Stefan Beller
This adds tests for the atomic push option. The first four tests check if the atomic option works in good conditions and the last three patches check if the atomic option prevents any change to be pushed if just one ref cannot be updated. Signed-off-by: Stefan Beller --- Notes: Changes v1 ->

[PATCHv2 1/6] receive-pack.c: add protocol support to negotiate atomic-push

2014-12-16 Thread Stefan Beller
From: Ronnie Sahlberg This adds support to the protocol between send-pack and receive-pack to * allow receive-pack to inform the client that it has atomic push capability * allow send-pack to request atomic push back. There is currently no setting in send-pack to actually request that atomic pus

[PATCHv2 3/6] send-pack.c: add --atomic command line argument

2014-12-16 Thread Stefan Beller
From: Ronnie Sahlberg This adds support to send-pack to negotiate and use atomic pushes iff the server supports it. Atomic pushes are activated by a new command line flag --atomic. In order to do this we also need to change the semantics for send_pack() slightly. The existing send_pack() functio

[PATCHv2 5/6] push.c: add an --atomic-push argument

2014-12-16 Thread Stefan Beller
From: Ronnie Sahlberg Add a command line argument to the git push command to request atomic pushes. Signed-off-by: Ronnie Sahlberg Signed-off-by: Stefan Beller --- Notes: Changes v1 -> v2 It's --atomic now! (dropping the -push) Documentation/git-push.txt | 7 ++- builtin/pus

Re: [PATCH] remote: allow adding remote w same name as alias

2014-12-16 Thread Anastas Dancha
My bad Johannes, Then I wrote "alias", I've meant the following: ``` [url "g...@githost.com"] insteadOf = myalias pushInsteadOf = myalias ``` Unfortunately, your suggested fix will not allow my [poorly] described use case. Hope this makes more sense now. Thank you for looking into this. -Anastas

Re: [PATCH] remote: allow adding remote w same name as alias

2014-12-16 Thread Michael J Gruber
Anastas Dancha schrieb am 16.12.2014 um 03:30: > From f80bdf3272e7bdf790ee67fb94196a8aa139331f Mon Sep 17 00:00:00 2001 > From: Anastas Dancha > Date: Mon, 15 Dec 2014 16:30:50 -0500 > Subject: [PATCH] remote: allow adding remote w same name as alias > > When ~/.gitconfig contains an alias (i.e.

Re: [PATCH] remote: allow adding remote w same name as alias

2014-12-16 Thread Johannes Schindelin
Hi Anastas, On Tue, 16 Dec 2014, Anastas Dancha wrote: > When ~/.gitconfig contains an alias (i.e. myremote) > and you are adding a new remote using the same name > for remote, Git will refuse to add the remote with > the same name as one of the aliases, even though the > remote with such name is

[PATCH 1/1] tests: make comment match the code

2014-12-16 Thread Christian Hesse
GnuPG homedir is generated on the fly and keys are imported from armored key file. Make commet match available key info and new key generation procedure. Signed-off-by: Christian Hesse --- t/lib-gpg.sh | 16 +--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/t/lib-gp