Re: [git-users] More on that "merge branch checkout" problem -- cannot abort/go back?

2017-01-31 Thread Michael
This is going to the main git list. I had an issue with a git gui checkin, where I did a checkin of selected lines (no problem), then tried to switch branches and check in the rest. Things broke. I attempted to get help on the git users list, but was unable to. To recap what happened: 1. I

Re: git push failing when push.recurseSubmodules on-demand and git commit --amend was used in submodule.

2017-01-31 Thread Carlo Wood
On Sun, 29 Jan 2017 17:00:22 -0800 Junio C Hamano wrote: > I suspect the submodule folks would say it is working as intended, > if \ > > - you made a commit in the submodule; > - recorded the resulting commit in the superproject; > - you amended the commit in the

Re: git push failing when push.recurseSubmodules on-demand and git commit --amend was used in submodule.

2017-01-31 Thread Carlo Wood
On Tue, 31 Jan 2017 14:08:41 -0800 Stefan Beller wrote: > On Sun, Jan 29, 2017 at 5:00 PM, Junio C Hamano > wrote: > > 2. If the amend is good and ready to go, "git add" to update the > > superproject to make that amended result the one that is needed

Re: [PATCH] color_parse_mem: allow empty color spec

2017-01-31 Thread Jacob Keller
On Tue, Jan 31, 2017 at 4:21 PM, Jeff King wrote: > On Tue, Jan 31, 2017 at 02:45:40PM -0800, Junio C Hamano wrote: > >> * nd/log-graph-configurable-colors (2017-01-23) 3 commits >> (merged to 'next' on 2017-01-23 at c369982ad8) >> + log --graph: customize the graph lines with

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Ramsay Jones
On 31/01/17 21:02, René Scharfe wrote: [snip] >> It would be trivially "optimized" out of the box, even when compiling with >> Tiny C or in debug mode. > > Such a compiler is already slowed down by memset(3) calls for initializing > objects and lack of other optimizations. I doubt a few more

[PATCH] color_parse_mem: allow empty color spec

2017-01-31 Thread Jeff King
On Tue, Jan 31, 2017 at 02:45:40PM -0800, Junio C Hamano wrote: > * nd/log-graph-configurable-colors (2017-01-23) 3 commits > (merged to 'next' on 2017-01-23 at c369982ad8) > + log --graph: customize the graph lines with config log.graphColors > + color.c: trim leading spaces in

What's cooking in git.git (Jan 2017, #06; Tue, 31)

2017-01-31 Thread Junio C Hamano
What's cooking in git.git (Jan 2017, #06; Tue, 31) -- Here are the topics that have been cooking. Commits prefixed with '-' are only in 'pu' (proposed updates) while commits prefixed with '+' are in 'next'. The ones marked with '.' do not appear

Re: [PATCH 3/7] completion: improve bash completion for git-add

2017-01-31 Thread SZEDER Gábor
> Add some long-options for git-add and improve path completion when the > --update flag is given. Please tell us in the commit message _how_ this improves path completion. > --- > contrib/completion/git-completion.bash | 10 +++--- > 1 file changed, 7 insertions(+), 3 deletions(-) > >

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Jeff King
On Tue, Jan 31, 2017 at 02:29:51PM -0800, Junio C Hamano wrote: > Jeff King writes: > > > ... I wonder if it would be more natural for it to take > > pointers-to-objects, making it look more like a real function (i.e., > > SWAP(, ) instead of SWAP(a, b)". And then these funny

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Junio C Hamano
Jeff King writes: > ... I wonder if it would be more natural for it to take > pointers-to-objects, making it look more like a real function (i.e., > SWAP(, ) instead of SWAP(a, b)". And then these funny corner cases > become quite obvious in the caller, because the caller is the

Re: [PATCH v2 7/7] completion: recognize more long-options

2017-01-31 Thread SZEDER Gábor
On Fri, Jan 27, 2017 at 10:17 PM, wrote: > From: Cornelius Weig > > Recognize several new long-options for bash completion in the following > commands: Adding more long options that git commands learn along the way is always an

Re: [PATCH 4/4] git-prompt.sh: add tests for submodule indicator

2017-01-31 Thread Junio C Hamano
SZEDER Gábor writes: > On Mon, Jan 30, 2017 at 9:44 PM, Benjamin Fuchs > wrote: >> Signed-off-by: Benjamin Fuchs >> --- >> t/t9903-bash-prompt.sh | 43 +++ >> 1 file changed, 43

Re: [PATCH 4/4] git-prompt.sh: add tests for submodule indicator

2017-01-31 Thread Stefan Beller
On Tue, Jan 31, 2017 at 2:06 PM, Junio C Hamano wrote: > SZEDER Gábor writes: > >> On Mon, Jan 30, 2017 at 9:44 PM, Benjamin Fuchs >> wrote: >>> Signed-off-by: Benjamin Fuchs >>> --- >>>

Re: gitconfig get out of sync with submodule entries on branch switch

2017-01-31 Thread Stefan Beller
On Mon, Jan 30, 2017 at 11:46 PM, Benjamin Schindler wrote: > Hi Brandon > > I did try your suggestion, so basically: > > git checkout branch > git submodule init > git submodule update Eventually this becomes git submudule update --init git checkout

Re: git push failing when push.recurseSubmodules on-demand and git commit --amend was used in submodule.

2017-01-31 Thread Stefan Beller
On Sun, Jan 29, 2017 at 5:00 PM, Junio C Hamano wrote: > Carlo Wood writes: > >> there seems to be a problem with using 'git commit --amend' in >> git submodules when using 'git push --recurse-submodules=on-demand' >> in the parent. >> >> The latter fails,

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Junio C Hamano
Cornelius Weig writes: > On 01/31/2017 06:08 PM, Junio C Hamano wrote: >> I think it is probably a good idea to document the behaviour >> (i.e. "--no-create" single-shot from the command line is ignored). >> I am not sure we should error out, though, in order to

Re: [PATCH v3 14/21] read-cache: touch shared index files when used

2017-01-31 Thread Junio C Hamano
Junio C Hamano writes: > Yes, but you need to realize that "it is better not to bother users > with a report of failure to touch in read-only repository" and "we > ignore all failures". Sorry about an unfinished sentence here. "need to realize that ... and ... are different

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Jeff King
On Tue, Jan 31, 2017 at 10:03:01PM +0100, René Scharfe wrote: > > Perhaps we could disallow a side-effect operator in the macro. By > > disallow I mean place a comment at the definition to the macro and > > hopefully catch something like that in code-review. We have the same > > issue with the

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread René Scharfe
Am 30.01.2017 um 23:21 schrieb Brandon Williams: On 01/30, René Scharfe wrote: Am 30.01.2017 um 22:03 schrieb Johannes Schindelin: It is curious, though, that an expression like "sizeof(a++)" would not be rejected. Clang normally warns about something like this ("warning: expression with

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread René Scharfe
Am 31.01.2017 um 13:13 schrieb Johannes Schindelin: Hi René, On Mon, 30 Jan 2017, René Scharfe wrote: Am 30.01.2017 um 21:48 schrieb Johannes Schindelin: The commit you quoted embarrasses me, and I have no excuse for it. I would love to see that myswap() ugliness fixed by replacing it with

Re: [PATCH 3/5] use SWAP macro

2017-01-31 Thread René Scharfe
Am 30.01.2017 um 23:22 schrieb Junio C Hamano: René Scharfe writes: if (tree2->flags & UNINTERESTING) { - struct object *tmp = tree2; - tree2 = tree1; - tree1 = tmp; +

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Cornelius Weig
On 01/31/2017 06:08 PM, Junio C Hamano wrote: > I think it is probably a good idea to document the behaviour > (i.e. "--no-create" single-shot from the command line is ignored). > I am not sure we should error out, though, in order to "disallow" > it---a documented silent no-op may be sufficient.

Re: vger not relaying some of Junio's messages today?

2017-01-31 Thread Junio C Hamano
Jeff King writes: > On Fri, Jan 27, 2017 at 03:57:53AM +, Eric Wong wrote: > >> I noticed both of these are are missing from my archives >> (which rejects messages unless they come from vger): >> >> >>

Re: [PATCH] Documentation: implement linkgit macro for Asciidoctor

2017-01-31 Thread Junio C Hamano
"brian m. carlson" writes: > On Thu, Jan 26, 2017 at 07:18:41PM +, Eric Wong wrote: >> > Eric Wong writes: >> Junio C Hamano wrote: >> > + "\n" >> > +"#{target}" >> > +"#{attrs[1]}\n" >> > +

Re: [PATCH] blame: draft of line format

2017-01-31 Thread Jeff King
On Mon, Jan 30, 2017 at 08:28:30PM -0600, Edmundo Carmona Antoranz wrote: > +static void pretty_info(char* revid, struct blame_entry *ent, struct strbuf > *rev_buffer) > +{ > + struct pretty_print_context ctx = {0}; > + struct rev_info rev; > + > + struct strbuf format = STRBUF_INIT;

Re: [PATCH v3 14/21] read-cache: touch shared index files when used

2017-01-31 Thread Junio C Hamano
Christian Couder writes: >> You are listing only the irrelevant cases. The shared one may be >> used immediately, and the user can keep using it for a while without >> "touching". > > Now you are talking about a case where the shared index file can be > used

[PATCH] .mailmap: update Gábor Szeder's email address

2017-01-31 Thread SZEDER Gábor
Signed-off-by: SZEDER Gábor --- .mailmap | 1 + 1 file changed, 1 insertion(+) diff --git a/.mailmap b/.mailmap index 9c87a3840..ab59b2fac 100644 --- a/.mailmap +++ b/.mailmap @@ -225,6 +225,7 @@ Steven Walter Steven Walter

Re: [PATCH 4/4] git-prompt.sh: add tests for submodule indicator

2017-01-31 Thread SZEDER Gábor
On Mon, Jan 30, 2017 at 9:44 PM, Benjamin Fuchs wrote: > Signed-off-by: Benjamin Fuchs > --- > t/t9903-bash-prompt.sh | 43 +++ > 1 file changed, 43 insertions(+) > > diff --git a/t/t9903-bash-prompt.sh

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Jeff King
On Tue, Jan 31, 2017 at 03:00:33PM +0100, Cornelius Weig wrote: > Concerning branches, I fully agree. For git-branch, the > "--no-create-reflog" option does not make sense at all and should > produce an error. > > On the other hand, for tags it may make sense to override >

i need your Assistance

2017-01-31 Thread Dr . Kürtiné Melik Anna

Re: [PATCH 2/4] git-prompt.sh: rework of submodule indicator

2017-01-31 Thread SZEDER Gábor
> Rework of the first patch. The prompt now will look like this: > (+name:master). I tried to considere all suggestions. > Tests still missing. > > Signed-off-by: Benjamin Fuchs > --- > contrib/completion/git-prompt.sh | 49 > >

Feature request: flagging “volatile” branches for integration/development

2017-01-31 Thread Herbert, Marc
(Thanks to Josh Triplett[*] for contributing to this message) Hi, We often work with development/integration branches that regularly rebase, in addition to stable branches that do not. Git is used to share two different types of branches: 1. Pull requests and merged code with final SHA1s 2.

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Junio C Hamano
Jeff King writes: > So I agree the current behavior is quietly broken, which is not good. > But I wonder if "--no-create-reflog" is really sane in the first place, > and whether we might be better off to simply disallow it. Thanks for a reasoned argument and a reasonable

Re: [PATCH] t0001: don't let a default ACL interfere with the umask test

2017-01-31 Thread Junio C Hamano
Matt McCutchen writes: > The "init creates a new deep directory (umask vs. shared)" test expects > the permissions of newly created files to be based on the umask, which > fails if a default ACL is inherited from the working tree for git. So > attempt to remove a default

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Junio C Hamano
Cornelius Weig writes: > And again, thanks for not yelling. I overlooked that the > "should_autocreate_reflog" return value should have been negated as > shown below. Heh---I AM blind. I didn't spot it even though I was staring at the code and even tweaking it (for

Re: [PATCH v3 14/21] read-cache: touch shared index files when used

2017-01-31 Thread Christian Couder
On Wed, Jan 25, 2017 at 9:52 PM, Junio C Hamano wrote: > Christian Couder writes: > >> Well, when we cannot freshen a loose file (with >> freshen_loose_object()), we don't warn or die, we just write the loose >> file. But here we cannot write the

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Cornelius Weig
On 01/31/2017 12:37 AM, Jeff King wrote: > On Mon, Jan 30, 2017 at 01:58:10PM -0800, Junio C Hamano wrote: > >>> When writing the test for git-tag, I realized that the option >>> --no-create-reflog to git-tag does not take precedence over >>> logAllRefUpdate=always. IOW the setting

[PATCHv4] builtin/commit.c: switch to strbuf, instead of snprintf()

2017-01-31 Thread Elia Pinto
Switch to dynamic allocation with strbuf, so we can avoid dealing with magic numbers in the code and reduce the cognitive burden from the programmers. The original code is correct, but programmers no longer have to count bytes needed for static allocation to know that. As a side effect of this

Re: [PATCH v3 2/3] refs: add option core.logAllRefUpdates = always

2017-01-31 Thread Cornelius Weig
Hi, > The extra free(refname) is to plug the leak I pointed out, and the > type of refname is no longer const, because "const char *" cannot be > free()d without casting, and in this codepath I do not see a reason > to mark it as const. Ooops.. thanks for not yelling at me for that :-/ > When

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Johannes Schindelin
Hi René, On Mon, 30 Jan 2017, René Scharfe wrote: > Am 30.01.2017 um 21:48 schrieb Johannes Schindelin: > > > The commit you quoted embarrasses me, and I have no excuse for it. I > > would love to see that myswap() ugliness fixed by replacing it with a > > construct that is simpler, and

Re: [PATCH 1/5] add SWAP macro

2017-01-31 Thread Johannes Schindelin
Hi René, On Mon, 30 Jan 2017, René Scharfe wrote: > Am 30.01.2017 um 22:03 schrieb Johannes Schindelin: > > It is curious, though, that an expression like "sizeof(a++)" would not > > be rejected. > > Clang normally warns about something like this ("warning: expression > with side effects has no

Did you get my message this time?

2017-01-31 Thread Qatif Oil Grroup Of Companies.
-- Dear Friend, I would like to discuss a very important issue with you. I am writing to find out if this is your valid email. Please, let me know if this email is valid Kind regards Adrien Saif Attorney to Qatif Group of Companies

[PATCH v5 0/5] urlmatch: allow wildcard-based matches

2017-01-31 Thread Patrick Steinhardt
Hi, this is version 5 of my patch series. The previous version can be found at [1]. The use case is to be able to configure an HTTP proxy for all subdomains of a domain where there are hundreds of subdomains. This includes only a single change, interdiff is included below. The previous version

[PATCH v5 2/5] urlmatch: enable normalization of URLs with globs

2017-01-31 Thread Patrick Steinhardt
From: Patrick Steinhardt The `url_normalize` function is used to validate and normalize URLs. As such, it does not allow for some special characters to be part of the URLs that are to be normalized. As we want to allow using globs in some configuration keys making

[PATCH v5 4/5] urlmatch: include host in urlmatch ranking

2017-01-31 Thread Patrick Steinhardt
From: Patrick Steinhardt In order to be able to rank positive matches by `urlmatch`, we inspect the path length and user part to decide whether a match is better than another match. As all other parts are matched exactly between both URLs, this is the correct thing

[PATCH v5 1/5] mailmap: add Patrick Steinhardt's work address

2017-01-31 Thread Patrick Steinhardt
From: Patrick Steinhardt Signed-off-by: Patrick Steinhardt --- .mailmap | 1 + 1 file changed, 1 insertion(+) diff --git a/.mailmap b/.mailmap index 9c87a3840..ea59205b9 100644 --- a/.mailmap +++ b/.mailmap @@ -177,6 +177,7 @@ Paolo

[PATCH v5 3/5] urlmatch: split host and port fields in `struct url_info`

2017-01-31 Thread Patrick Steinhardt
From: Patrick Steinhardt The `url_info` structure contains information about a normalized URL with the URL's components being represented by different fields. The host and port part though are to be accessed by the same `host` field, so that getting the host and/or

[PATCH v5 5/5] urlmatch: allow globbing for the URL host part

2017-01-31 Thread Patrick Steinhardt
From: Patrick Steinhardt The URL matching function computes for two URLs whether they match not. The match is performed by splitting up the URL into different parts and then doing an exact comparison with the to-be-matched URL. The main user of `urlmatch` is the

Re: [PATCH v4 0/5] urlmatch: allow wildcard-based matches

2017-01-31 Thread Patrick Steinhardt
On Mon, Jan 30, 2017 at 02:52:00PM -0800, Junio C Hamano wrote: > Junio C Hamano writes: > > > Patrick Steinhardt writes: > > > >> - I realized that with my patches, "ranking" of URLs was broken. > >>Previously, we've always taken the longest