Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread René Scharfe
Am 10.05.2018 um 02:04 schrieb Junio C Hamano: > Taylor Blau writes: > >> This check we should retain and change the wording to mention '--and', >> '--or', and '--not' specifically. > > Why are these problematic in the first place? If I said > > $ git grep -e first

Re: [PATCH] Implement --first-parent for git rev-list --bisect

2018-05-09 Thread Christian Couder
Hi Tiago, On Wed, May 9, 2018 at 11:57 PM, Tiago Botelho wrote: > --- Please add something in the commit message (above the "---") about why this new feature is useful. For example you could just say that it will make it possible to implement bisecting on first parents

Re: [PATCH v2 0/5] getting rid of most "static struct lock_file"s

2018-05-09 Thread Jeff King
On Wed, May 09, 2018 at 10:55:34PM +0200, Martin Ågren wrote: > This is take two of my attempt at making almost all `struct lock_file`s > non-static. All patches have been equipped with more detailed commit > messages. The only diff that has changed is patch 3/5, where I now take > a small step

Re: [PATCH 1/2] packfile: close and free packs upon releasing an object store

2018-05-09 Thread Jeff King
On Wed, May 09, 2018 at 05:12:10PM -0700, Stefan Beller wrote: > In d0b59866223 (object-store: close all packs upon clearing the object > store, 2018-03-23), we made sure to close all packfiles on releasing > an object store, but we also have to free the memory of the closed packs. I know we've

Re: [PATCH 1/1] commit-graph: fix UX issue when .lock file exists

2018-05-09 Thread Jeff King
On Wed, May 09, 2018 at 10:53:56AM -0400, Derrick Stolee wrote: > > Your cover letter is way longer than this description. Should some of > > that background perhaps go in the commit message? > > I did want a place to include the full die() message in the new behavior, > but that seemed like

Re: [PATCH 4/5] lock_file: make function-local locks non-static

2018-05-09 Thread Junio C Hamano
Martin Ågren writes: > On 9 May 2018 at 18:19, Duy Nguyen wrote: >> On Tue, May 8, 2018 at 8:18 PM, Jeff King wrote: > >>> It should be totally safe. If you look at "struct lock_file", it is now >>> simply a pointer to a tempfile

Re: What's cooking in git.git (May 2018, #01; Mon, 7)

2018-05-09 Thread Junio C Hamano
Ben Peart writes: > On 5/7/2018 10:58 AM, Junio C Hamano wrote: > >> * bp/merge-rename-config (2018-05-04) 3 commits >> - merge: pass aggressive when rename detection is turned off >> - merge: add merge.renames config setting >> - merge: update documentation for

Re: [PATCH v3 09/12] get_short_oid / peel_onion: ^{tree} should be tree, not treeish

2018-05-09 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: >> Before we had any disambiguation code, resolving X^{tree} really was two >> independent steps: resolve X, and then peel it to a tree. When we added >> the disambiguation code, the goal was to provide a hint to the first >> step in such a way

[GSoC] Info: Week 02 Blog Post

2018-05-09 Thread Pratik Karki
Hi, The week 02 blog post[1] is live. This post is part I out of II and this time it will be biweekly. The part II of will come in 2-3 days which will describe the current `git-rebase.sh`. Do give me feedback. Thanks to all the awesome Git contributors for this awesome tool. :-) [1]:

Re: [PATCH 2/2] builtin/grep.c: teach '-o', '--only-matching' to 'git-grep'

2018-05-09 Thread Taylor Blau
On Tue, May 08, 2018 at 01:25:17PM -0400, Jeff King wrote: > On Sat, May 05, 2018 at 08:49:43AM +0200, Ævar Arnfjörð Bjarmason wrote: > > > > +test_expect_success 'grep --only-matching --heading' ' > > > + git grep --only-matching --heading --line-number --column mmap file > > > >actual && > > >

Proposal

2018-05-09 Thread Zeliha Omer Faruk
-- Hello Greetings to you please i have a business proposal for you contact me for more detailes asap thanks. Best Regards, Miss.Zeliha ömer faruk Esentepe Mahallesi Büyükdere Caddesi Kristal Kule Binasi No:215 Sisli - Istanbul, Turkey

[PATCH v4 04/13] alloc: add repository argument to alloc_blob_node

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 02/13] object: add repository argument to create_object

2018-05-09 Thread Stefan Beller
Add a repository argument to allow the callers of create_object to be more specific about which repository to act on. This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Signed-off-by: Jonathan Nieder

[PATCH v4 00/13] object store: alloc

2018-05-09 Thread Stefan Beller
v4: * address the memory issues, an interdiff is below. v3: * I used the (soon to be renamed?) branch-diff tool to attach a diff below between v2 and v3 * fixed comment in patch 1 * correctly free objects and its hashmap in the last patch. * drop free'ing the commit->util pointer as we do

[PATCH v4 11/13] object: allow grow_object_hash to handle arbitrary repositories

2018-05-09 Thread Stefan Beller
Reviewed-by: Jonathan Tan Signed-off-by: Jonathan Nieder Signed-off-by: Stefan Beller Signed-off-by: Junio C Hamano --- object.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff

[PATCH v4 08/13] alloc: add repository argument to alloc_object_node

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 05/13] alloc: add repository argument to alloc_tree_node

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 10/13] alloc: add repository argument to alloc_commit_index

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 06/13] alloc: add repository argument to alloc_commit_node

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 12/13] object: allow create_object to handle arbitrary repositories

2018-05-09 Thread Stefan Beller
Reviewed-by: Jonathan Tan Signed-off-by: Jonathan Nieder Signed-off-by: Stefan Beller Signed-off-by: Junio C Hamano --- object.c | 12 ++-- object.h | 3 +-- 2 files changed, 7 insertions(+), 8

[PATCH v4 07/13] alloc: add repository argument to alloc_tag_node

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 13/13] alloc: allow arbitrary repositories for alloc functions

2018-05-09 Thread Stefan Beller
We have to convert all of the alloc functions at once, because alloc_report uses a funky macro for reporting. It is better for the sake of mechanical conversion to convert multiple functions at once rather than changing the structure of the reporting function. We record all memory allocation in

[PATCH v4 09/13] alloc: add repository argument to alloc_report

2018-05-09 Thread Stefan Beller
This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet. Use a macro to catch callers passing a repository other than the_repository at compile time. Signed-off-by: Stefan Beller Signed-off-by: Junio C

[PATCH v4 03/13] object: add repository argument to grow_object_hash

2018-05-09 Thread Stefan Beller
From: Jonathan Nieder Add a repository argument to allow the caller of grow_object_hash to be more specific about which repository to handle. This is a small mechanical change; it doesn't change the implementation to handle repositories other than the_repository yet.

[PATCH v4 01/13] repository: introduce parsed objects field

2018-05-09 Thread Stefan Beller
Convert the existing global cache for parsed objects (obj_hash) into repository-specific parsed object caches. Existing code that uses obj_hash are modified to use the parsed object cache of the_repository; future patches will use the parsed object caches of other repositories. Another future use

[PATCH 2/2] packfile.h: remove all extern keywords

2018-05-09 Thread Stefan Beller
Per our coding guidelines we prefer to only use the extern keyword when needed. Signed-off-by: Stefan Beller --- packfile.h | 80 +++--- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/packfile.h b/packfile.h

[PATCH 1/2] packfile: close and free packs upon releasing an object store

2018-05-09 Thread Stefan Beller
In d0b59866223 (object-store: close all packs upon clearing the object store, 2018-03-23), we made sure to close all packfiles on releasing an object store, but we also have to free the memory of the closed packs. Signed-off-by: Stefan Beller --- object.c | 2 +-

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Junio C Hamano
Taylor Blau writes: > This check we should retain and change the wording to mention '--and', > '--or', and '--not' specifically. Why are these problematic in the first place? If I said $ git grep -e first --and -e these $ git grep -e first --and --not -e those $

Proposal

2018-05-09 Thread Zeliha Omer Faruk
-- Hello Greetings to you please i have a business proposal for you contact me for more detailes asap thanks. Best Regards, Miss.Zeliha ömer faruk Esentepe Mahallesi Büyükdere Caddesi Kristal Kule Binasi No:215 Sisli - Istanbul, Turkey

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Taylor Blau
On Wed, May 09, 2018 at 07:26:57PM +0200, Martin Ågren wrote: > On 9 May 2018 at 12:41, Phillip Wood wrote: > > On 09/05/18 03:13, Taylor Blau wrote: > >> > >> +--column:: > >> + Prefix the 1-indexed byte-offset of the first match on non-context > >> lines. This

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Taylor Blau
On Wed, May 09, 2018 at 11:41:02AM +0100, Phillip Wood wrote: > Hi Taylor > > On 09/05/18 03:13, Taylor Blau wrote: > > Teach 'git-grep(1)' a new option, '--column', to show the column > > number of the first match on a non-context line. This makes it possible > > to teach

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Taylor Blau
On Wed, May 09, 2018 at 06:17:20PM +0200, Duy Nguyen wrote: > On Wed, May 9, 2018 at 4:13 AM, Taylor Blau wrote: > > diff --git a/builtin/grep.c b/builtin/grep.c > > index 5f32d2ce84..f9f516dfc4 100644 > > --- a/builtin/grep.c > > +++ b/builtin/grep.c > > @@ -829,6 +829,7 @@

[PATCH 1/2] object.c: free replace map in raw_object_store_clear

2018-05-09 Thread Stefan Beller
The replace map for objects was missed to free in the object store in the conversion of 174774cd519 (Merge branch 'sb/object-store-replace', 2018-05-08) Signed-off-by: Stefan Beller --- object.c | 1 + 1 file changed, 1 insertion(+) diff --git a/object.c b/object.c index

[PATCH 2/2] replace-object.c: remove the_repository from prepare_replace_object

2018-05-09 Thread Stefan Beller
This was missed in 5982da9d2ce (replace-object: allow prepare_replace_object to handle arbitrary repositories, 2018-04-11) Technically the code works correctly as the replace_map is the same size in different repositories, however it is hard to read. So convert the code to the familiar pattern of

Proposal

2018-05-09 Thread Zeliha Omer Faruk
-- Hello Greetings to you please i have a business proposal for you contact me for more detailes asap thanks. Best Regards, Miss.Zeliha ömer faruk Esentepe Mahallesi Büyükdere Caddesi Kristal Kule Binasi No:215 Sisli - Istanbul, Turkey

RE: [Best Practices Request] clean/smudge configuration

2018-05-09 Thread Randall S. Becker
On May 9, 2018 6:39 PM, Bryan Turner wrote > > On Wed, May 9, 2018 at 3:09 PM Randall S. Becker > > wrote: > > > The question: what is the best practice for versioning the parts of > > clean/smudge filters that are in .git/config given that only some > > users in my

Re: [Best Practices Request] clean/smudge configuration

2018-05-09 Thread Bryan Turner
On Wed, May 9, 2018 at 3:09 PM Randall S. Becker wrote: > The question: what is the best practice for versioning the parts of > clean/smudge filters that are in .git/config given that only some users in > my environment will be cloning the repository in question and that

[Best Practices Request] clean/smudge configuration

2018-05-09 Thread Randall S. Becker
Hi Git Team, I'm trying to work out some best practices for managing clean/smudge filters and hit a bump. The situation is that I have an environment where the possible clean/smudge filter configuration can change over time and needs to be versioned with the product being managed in a git

Proposal

2018-05-09 Thread Zeliha Omer Faruk
-- Hello Greetings to you please i have a business proposal for you contact me for more detailes asap thanks. Best Regards, Miss.Zeliha ömer faruk Esentepe Mahallesi Büyükdere Caddesi Kristal Kule Binasi No:215 Sisli - Istanbul, Turkey

[PATCH] Implement --first-parent for git rev-list --bisect

2018-05-09 Thread Tiago Botelho
--- bisect.c | 53 +++-- bisect.h | 1 + builtin/rev-list.c | 3 +++ 3 files changed, 35 insertions(+), 22 deletions(-) diff --git a/bisect.c b/bisect.c index 4eafc8262..f43713574 100644 --- a/bisect.c +++ b/bisect.c @@ -34,7

Re: [PATCH] fast-export: avoid NULL pointer arithmetic

2018-05-09 Thread Johannes Schindelin
Hi René, On Wed, 9 May 2018, René Scharfe wrote: > Clang 6 reports the following warning, which is turned into an error in a > DEVELOPER build: > > builtin/fast-export.c:162:28: error: performing pointer arithmetic on a > null pointer has undefined behavior

[PATCH 1/2] git-credential-netrc: adapt to test framework for git

2018-05-09 Thread Luis Marsano
until this change, git-credential-netrc did not test in a repository this change reuses the main test framework, which provides such tests specific changes - switch to Test::More module - use File::Basename & File::Spec::Functions Signed-off-by: Luis Marsano Acked-by: Ted

[PATCH 2/2] git-credential-netrc: accept gpg option

2018-05-09 Thread Luis Marsano
git-credential-netrc was hardcoded to decrypt with 'gpg' regardless of the gpg.program option this now uses the gpg command option if set, else, the gpg.program option set in the git repository or global configuration, else defaults to 'gpg' for git-credential-netrc - use Git.pm for repository

[PATCH 0/2] Configurable GnuPG command for git-credential-netrc

2018-05-09 Thread Luis Marsano
Hi everyone, Should `contrib/` area patches go here, too? Contributed Software page https://git.kernel.org/pub/scm/git/git.git/tree/contrib/README says to forward them to "jc" (I'm guessing that's Junio), but I think they're getting missed. Though the component author approves (acknowledgement

Proposal

2018-05-09 Thread Zeliha Omer Faruk
-- Hello Greetings to you please i have a business proposal for you contact me for more detailes asap thanks. Best Regards, Miss.Zeliha ömer faruk Esentepe Mahallesi Büyükdere Caddesi Kristal Kule Binasi No:215 Sisli - Istanbul, Turkey

[PATCH] fast-export: avoid NULL pointer arithmetic

2018-05-09 Thread René Scharfe
Clang 6 reports the following warning, which is turned into an error in a DEVELOPER build: builtin/fast-export.c:162:28: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic] return ((uint32_t *)NULL) + mark;

[PATCH v2 5/5] lock_file: move static locks into functions

2018-05-09 Thread Martin Ågren
Placing `struct lock_file`s on the stack used to be a bad idea, because the temp- and lockfile-machinery would keep a pointer into the struct. But after 076aa2cbd (tempfile: auto-allocate tempfiles on heap, 2017-09-05), we can safely have lockfiles on the stack. (This applies even if a user

[PATCH v2 2/5] refs.c: do not die if locking fails in `write_pseudoref()`

2018-05-09 Thread Martin Ågren
If we could not take the lock, we add an error to the `strbuf err` and return. However, this code is dead. The reason is that we take the lock using `LOCK_DIE_ON_ERROR`. Drop the flag to allow our more gentle error-handling to actually kick in. We could instead just drop the dead code and die

[PATCH v2 4/5] lock_file: make function-local locks non-static

2018-05-09 Thread Martin Ågren
Placing `struct lock_file`s on the stack used to be a bad idea, because the temp- and lockfile-machinery would keep a pointer into the struct. But after 076aa2cbd (tempfile: auto-allocate tempfiles on heap, 2017-09-05), we can safely have lockfiles on the stack. (This applies even if a user

[PATCH v2 1/5] t/helper/test-write-cache: clean up lock-handling

2018-05-09 Thread Martin Ågren
Die in case writing the index fails, so that the caller can notice (instead of, say, being impressed by how performant the writing is). While at it, note that after opening a lock with `LOCK_DIE_ON_ERROR`, we do not need to worry about whether we succeeded. Also, we can move the `struct

[PATCH v2 3/5] refs.c: do not die if locking fails in `delete_pseudoref()`

2018-05-09 Thread Martin Ågren
After taking the lock we check whether we got it and die otherwise. But since we take the lock using `LOCK_DIE_ON_ERROR`, we would already have died. Considering the choice between dropping the dead code and dropping the flag, let's go for option number three: Drop the flag, write an error

[PATCH v2 0/5] getting rid of most "static struct lock_file"s

2018-05-09 Thread Martin Ågren
This is take two of my attempt at making almost all `struct lock_file`s non-static. All patches have been equipped with more detailed commit messages. The only diff that has changed is patch 3/5, where I now take a small step towards gentle error-handling, rather than going in the opposite

Re: [PATCH] t6050-replace: don't disable stdin for the whole test script

2018-05-09 Thread SZEDER Gábor
On Tue, May 8, 2018 at 10:53 PM, Johannes Schindelin wrote: > On Mon, 7 May 2018, SZEDER Gábor wrote: > >> The test script 't6050-replace.sh' starts off with redirecting the whole >> test script's stdin from /dev/null. This redirection has been there >> since the test

Re: [PATCH v1] add status config and command line options for rename detection

2018-05-09 Thread Ben Peart
On 5/9/2018 12:56 PM, Elijah Newren wrote: Hi Ben, Overall I think this is good, but I have lots of nit-picky things to bring up. :-) Thank you for the review. I appreciate the extra set of eyes on these changes. Especially when dealing with the merge logic and settings which I am

Re: Is rebase --force-rebase any different from rebase --no-ff?

2018-05-09 Thread Ilya Kantor
I tried to compare --force-rebase VS --no-ff for the following repository: http://jmp.sh/E7TRjcL There's no difference in the resulf of: git rebase --force-rebase 54a4 git rebase --no-ff 54a4 (rebases all 3 commits of feature) Also, there's no difference in interactive mode: git rebase

Hello

2018-05-09 Thread Mrs Pamela Atuegbe
Am Mrs.Pamela Atuegbe, I work in one of the prime bank here in burkina faso, I want the bank to transfer the money left by our late customer is a foreigner from Korea. can you investment this money and also help the poor' the amount value at $13,300,000.00 (Thirteen Million Three Hundred

Re: Is rebase --force-rebase any different from rebase --no-ff?

2018-05-09 Thread Marc Branchaud
On 2018-05-09 02:21 PM, Stefan Beller wrote: +cc Marc and Johannes who know more about rebase. On Wed, May 9, 2018 at 9:01 AM, Ilya Kantor wrote: Right now in "git help rebase" for --no-ff: "Without --interactive, this is a synonym for --force-rebase." But *with*

Re: [PATCH v3 13/13] alloc: allow arbitrary repositories for alloc functions

2018-05-09 Thread Stefan Beller
On Wed, May 9, 2018 at 10:18 AM, Duy Nguyen wrote: > > If you want to reproduce, this is what I used to test this with. > > https://gist.github.com/pclouds/86a2df6c28043f1b6fa3d4e72e7a1276 This only applied cleanly after I created an empty file at t/helper/test-abc.c, using

Re: Implementing reftable in Git

2018-05-09 Thread Ævar Arnfjörð Bjarmason
On Wed, May 09 2018, Stefan Beller wrote: > Hi Christian, > > On Wed, May 9, 2018 at 7:33 AM, Christian Couder > wrote: >> Hi, >> >> I might start working on implementing reftable in Git soon. > > Cool! Everyone is waiting for it as they dream about the > performance

Re: [PATCH v2 0/2] gitk: improve handling of submodules in the file list panel

2018-05-09 Thread Stefan Beller
On Wed, May 9, 2018 at 5:35 AM, Alex Riesen wrote: > From: Alex Riesen > > Currently, the submodule entries in the file list panel are mostly ignored. > This series attempts to improve the situation by showing part of submodule > history when

Re: [PATCH] sha1dc: fix for compiling on AIX using IBM XLC compiler

2018-05-09 Thread Jonathan Nieder
(+cc: Marc Stevens) Ævar Arnfjörð Bjarmason wrote: > On Wed, May 09 2018, jens persson wrote: >> Hello, first patch. I'm having trouble compiling on AIX using IBMs >> compiler, leading to >> unusable binaries. The following patch solved the problem for 2.17.0. >> The patch below is cut via gmail

Re: Is rebase --force-rebase any different from rebase --no-ff?

2018-05-09 Thread Stefan Beller
+cc Marc and Johannes who know more about rebase. On Wed, May 9, 2018 at 9:01 AM, Ilya Kantor wrote: > Right now in "git help rebase" for --no-ff: > "Without --interactive, this is a synonym for --force-rebase." > > But *with* --interactive, is there any difference? I found

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Stefan Beller
On Wed, May 9, 2018 at 11:00 AM, Duy Nguyen wrote: > On Wed, May 9, 2018 at 7:50 PM, Stefan Beller wrote: >>> I was trying to test the new parsed_object_pool_clear() and found this. >> >> So this would go with the latest sb/object-store-alloc ? > > No this

Re: Implementing reftable in Git

2018-05-09 Thread Carlos Martín Nieto
On Wed, 2018-05-09 at 10:54 -0700, Jonathan Nieder wrote: > Carlos Martín Nieto wrote: > > On Wed, 2018-05-09 at 09:48 -0700, Jonathan Nieder wrote: > > > If you would like the patches at https://git.eclipse.org/r/q/topi > > > c:reftable > > > relicensed for Git's use so that you don't need to

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 7:50 PM, Stefan Beller wrote: >> I was trying to test the new parsed_object_pool_clear() and found this. > > So this would go with the latest sb/object-store-alloc ? No this should be separate because sb/object-store-alloc did not even touch this code.

Re: Implementing reftable in Git

2018-05-09 Thread Stefan Beller
On Wed, May 9, 2018 at 10:48 AM, Jonathan Nieder wrote: > Stefan Beller wrote: > >> * We *might* be able to use reftables in negotiation later >> ("client: Last I fetched, you said your latest transaction >> number was '5' with the hash over all refs to be ; >> server:

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 7:42 PM, Elijah Newren wrote: > On Wed, May 9, 2018 at 10:04 AM, Nguyễn Thái Ngọc Duy > wrote: >> the_repository is special. One of the special things about it is that >> it does not allocate a new index_state object like submodules

Re: Implementing reftable in Git

2018-05-09 Thread Jonathan Nieder
Carlos Martín Nieto wrote: > On Wed, 2018-05-09 at 09:48 -0700, Jonathan Nieder wrote: >> If you would like the patches at https://git.eclipse.org/r/q/topic:reftable >> relicensed for Git's use so that you don't need to include that >> license header, let me know. Separate from any legal

Re: Implementing reftable in Git

2018-05-09 Thread Carlos Martín Nieto
Hi all, On Wed, 2018-05-09 at 09:48 -0700, Jonathan Nieder wrote: > Hi, > > Christian Couder wrote: > > > I might start working on implementing reftable in Git soon. > > Yay! > > [...] > > So I think the most straightforward and compatible way to do it would > > be to port the JGit

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Stefan Beller
On Wed, May 9, 2018 at 10:04 AM, Nguyễn Thái Ngọc Duy wrote: > the_repository is special. One of the special things about it is that > it does not allocate a new index_state object like submodules but > points to the global the_index variable instead. As a global variable, >

Re: Implementing reftable in Git

2018-05-09 Thread Jonathan Nieder
Stefan Beller wrote: > * We *might* be able to use reftables in negotiation later > ("client: Last I fetched, you said your latest transaction > number was '5' with the hash over all refs to be ; > server: ok, here are the refs and the pack, you're welcome"). Do you mean that reftable's

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Elijah Newren
On Wed, May 9, 2018 at 10:04 AM, Nguyễn Thái Ngọc Duy wrote: > the_repository is special. One of the special things about it is that > it does not allocate a new index_state object like submodules but > points to the global the_index variable instead. As a global variable, >

Re: Implementing reftable in Git

2018-05-09 Thread Stefan Beller
Hi Christian, On Wed, May 9, 2018 at 7:33 AM, Christian Couder wrote: > Hi, > > I might start working on implementing reftable in Git soon. Cool! Everyone is waiting for it as they dream about the performance and correctness benefits this brings. Benefits that I

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Martin Ågren
On 9 May 2018 at 12:41, Phillip Wood wrote: > On 09/05/18 03:13, Taylor Blau wrote: >> >> +--column:: >> + Prefix the 1-indexed byte-offset of the first match on non-context >> lines. This >> + option is incompatible with '--invert-match', and extended >>

Re: [PATCH] doc: fix config API documentation about config_with_options

2018-05-09 Thread Brandon Williams
On 05/09, Antonio Ospite wrote: > In commit dc8441fdb ("config: don't implicitly use gitdir or commondir", > 2017-06-14) the function git_config_with_options was renamed to > config_with_options to better reflect the fact that it does not access > the git global config or the repo config by

Re: [PATCH v3 13/13] alloc: allow arbitrary repositories for alloc functions

2018-05-09 Thread Duy Nguyen
On Tue, May 8, 2018 at 10:04 PM, Jonathan Tan wrote: > On Tue, 8 May 2018 12:37:36 -0700 > Stefan Beller wrote: > >> +void clear_alloc_state(struct alloc_state *s) >> +{ >> + while (s->slab_nr > 0) { >> + s->slab_nr--; >> +

Re: [PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Brandon Williams
On 05/09, Nguyễn Thái Ngọc Duy wrote: > the_repository is special. One of the special things about it is that > it does not allocate a new index_state object like submodules but > points to the global the_index variable instead. As a global variable, > the_index cannot be free()'d. > > Add an

Re: [PATCHv2 0/4] Rebooting pc/submodule-helper-foreach

2018-05-09 Thread Jonathan Tan
On Tue, 8 May 2018 17:29:48 -0700 Stefan Beller wrote: > v2: > * rebased onto origin/master > * dropped leftover "toplevel" variable from experimentation > * reworded the commit message for the first patch extensively > * dropped the third patch > * see "branch-diff" below.

Re: [PATCH 4/5] lock_file: make function-local locks non-static

2018-05-09 Thread Martin Ågren
On 9 May 2018 at 18:19, Duy Nguyen wrote: > On Tue, May 8, 2018 at 8:18 PM, Jeff King wrote: >> It should be totally safe. If you look at "struct lock_file", it is now >> simply a pointer to a tempfile allocated on the heap (in fact, I thought >> about getting

[PATCH] repository: fix free problem with repo_clear(the_repository)

2018-05-09 Thread Nguyễn Thái Ngọc Duy
the_repository is special. One of the special things about it is that it does not allocate a new index_state object like submodules but points to the global the_index variable instead. As a global variable, the_index cannot be free()'d. Add an exception for this in repo_clear(). In the future

Re: [PATCH v1] add status config and command line options for rename detection

2018-05-09 Thread Ben Peart
On 5/9/2018 11:59 AM, Duy Nguyen wrote: On Wed, May 9, 2018 at 4:42 PM, Ben Peart wrote: Add a new config status.renames setting to enable turning off rename detection during status. This setting will default to the value of diff.renames. Please add the reason you

[PATCH] BUG_exit_code: fix sparse "symbol not declared" warning

2018-05-09 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Johannes, If you need to re-roll your 'js/use-bug-macro' branch, could you please squash this into the relevant patch (commit a86303cb5d, "test-tool: help verifying BUG() code paths", 2018-05-02). This will, obviously, not be

Re: [PATCH v1] add status config and command line options for rename detection

2018-05-09 Thread Elijah Newren
Hi Ben, Overall I think this is good, but I have lots of nit-picky things to bring up. :-) On Wed, May 9, 2018 at 7:42 AM, Ben Peart wrote: > Add status --no-renames command line option that enables overriding the config > setting from the command line. Add

Re: regarding fix on "git clone $there $here"

2018-05-09 Thread Leslie Wang
Thanks for the confirmation. It is very helpful! Best Regards Leslie Wang > On May 8, 2018, at 11:44 PM, Junio C Hamano wrote: > > Leslie Wang writes: > >> At 2.14.1 or 2.15.1, if I run command like >> - mkdir /tmp/111 >> - git clone

Re: Implementing reftable in Git

2018-05-09 Thread Jonathan Nieder
Hi, Christian Couder wrote: > I might start working on implementing reftable in Git soon. Yay! [...] > So I think the most straightforward and compatible way to do it would > be to port the JGit implementation. I suspect following the spec[1] would be even more compatible, since it would

Re: Can not save changes into stash

2018-05-09 Thread Torsten Bögershausen
[Please no top posting here] On 09.05.18 15:27, KES wrote: > I even can not drop local changes: > > $ git checkout local.conf > error: pathspec 'local.conf' did not match any file(s) known to git. > > $ git log local.conf > commit 6df8bab88fd703c6859954adc51b2abaad8f59ec > Author: Eugen Konkov

Re: [PATCH 02/18] Add a new builtin: branch-diff

2018-05-09 Thread Ramsay Jones
On 05/05/18 20:41, Johannes Schindelin wrote: [snip] [Sorry for the late reply - still catching up after (long weekend) UK public holiday] > Well, what I would want to do is let the cloud work for me. By adding an > automated build to my Visual Studio Team Services (VSTS) account, of > course,

Re: [PATCH 4/5] lock_file: make function-local locks non-static

2018-05-09 Thread Duy Nguyen
On Tue, May 8, 2018 at 8:18 PM, Jeff King wrote: > On Mon, May 07, 2018 at 05:24:05PM +0200, Duy Nguyen wrote: > >> - static struct lock_file lock; >> + struct lock_file lock = LOCK_INIT; >> >>> >> >>> Is it really safe to do this? I vaguely remember something

Re: [PATCH v5 5/7] builtin/grep.c: add '--column' option to 'git-grep(1)'

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 4:13 AM, Taylor Blau wrote: > diff --git a/builtin/grep.c b/builtin/grep.c > index 5f32d2ce84..f9f516dfc4 100644 > --- a/builtin/grep.c > +++ b/builtin/grep.c > @@ -829,6 +829,7 @@ int cmd_grep(int argc, const char **argv, const char > *prefix) >

Re: Implementing reftable in Git

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 4:33 PM, Christian Couder wrote: > Hi, > > I might start working on implementing reftable in Git soon. Adding Michael Haggerty who did lots of work on ref stuff. He probably can give a few suggestions. You probably should also look at the last

Re: [PATCH 0/1] Fix UX issue with commit-graph.lock

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 4:15 PM, Derrick Stolee wrote: > We use the lockfile API to avoid multiple Git processes from writing to > the commit-graph file in the .git/objects/info directory. In some cases, > this directory may not exist, so we check for its existence. > > The

Is rebase --force-rebase any different from rebase --no-ff?

2018-05-09 Thread Ilya Kantor
Right now in "git help rebase" for --no-ff: "Without --interactive, this is a synonym for --force-rebase." But *with* --interactive, is there any difference? After doing some tests and looking in the source I couldn't find any difference between those two at all. Probably, there was a

Re: [PATCH v1] add status config and command line options for rename detection

2018-05-09 Thread Duy Nguyen
On Wed, May 9, 2018 at 4:42 PM, Ben Peart wrote: > Add a new config status.renames setting to enable turning off rename detection > during status. This setting will default to the value of diff.renames. Please add the reason you need this config key in the commit

Re: [PATCH] wrap-for-bin.sh: facilitate running Git executables under valgrind

2018-05-09 Thread Antonio Ospite
On Wed, 9 May 2018 08:25:21 -0700 Elijah Newren wrote: > Hi Antonio, > Hi Elijah, > On Wed, May 9, 2018 at 6:28 AM, Antonio Ospite wrote: > > Testing locally built git executables under valgrind is not immediate. > > > > Something like the following does not

Re: [PATCH v3 13/13] alloc: allow arbitrary repositories for alloc functions

2018-05-09 Thread Duy Nguyen
On Tue, May 8, 2018 at 10:37 PM, Stefan Beller wrote: >>> +void release_tree_node(struct tree *t); >>> +void release_commit_node(struct commit *c); >>> +void release_tag_node(struct tag *t); >> >> Do these really need to be defined in alloc.c? I would think that it >> would be

Re: [PATCH] wrap-for-bin.sh: facilitate running Git executables under valgrind

2018-05-09 Thread Elijah Newren
Hi Antonio, On Wed, May 9, 2018 at 6:28 AM, Antonio Ospite wrote: > Testing locally built git executables under valgrind is not immediate. > > Something like the following does not work: > > $ valgrind ./bin-wrappers/git > > because the wrapper script forks and execs the command

Re: [PATCH 1/1] commit-graph: fix UX issue when .lock file exists

2018-05-09 Thread Derrick Stolee
On 5/9/2018 10:42 AM, Jeff King wrote: On Wed, May 09, 2018 at 02:15:38PM +, Derrick Stolee wrote: The commit-graph file lives in the .git/objects/info directory. Previously, a failure to acquire the commit-graph.lock file was assumed to be due to the lack of the info directory, so a

Re: Implementing reftable in Git

2018-05-09 Thread Derrick Stolee
On 5/9/2018 10:33 AM, Christian Couder wrote: Hi, I might start working on implementing reftable in Git soon. During the last Git Merge conference last March Stefan talked about reftable. In Alex Vandiver's notes [1] it is asked that people announce it on the list when they start working on

Re: [PATCH] wrap-for-bin.sh: facilitate running Git executables under valgrind

2018-05-09 Thread Jeff King
On Wed, May 09, 2018 at 03:28:58PM +0200, Antonio Ospite wrote: > Testing locally built git executables under valgrind is not immediate. > > Something like the following does not work: > > $ valgrind ./bin-wrappers/git > > because the wrapper script forks and execs the command and valgrind

[PATCH v1] add status config and command line options for rename detection

2018-05-09 Thread Ben Peart
Add a new config status.renames setting to enable turning off rename detection during status. This setting will default to the value of diff.renames. Add a new config status.renamelimit setting to to enable bounding the time spent finding out inexact renames during status. This setting will

  1   2   >