[PATCH 10/10] ls-partial: created command to list missing blobs

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler Added a command to list the missing blobs for a commit. This can be used after a partial clone or fetch to list the omitted blobs that the client would need to checkout the given commit/branch. Optionally respecting or ignoring the current

[PATCH] submodule--helper.c: remove duplicate code

2017-03-08 Thread me
From: Valery Tolstov Remove code fragment from module_clone that duplicates functionality of connect_work_tree_and_git_dir in dir.c Signed-off-by: Valery Tolstov --- >> I think we can reuse code from module_clone that writes .git link. >> Possibly this

[PATCH 03/10] pack-objects: test for --partial-by-size --partial-special

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler Some simple tests for pack-objects with the new --partial-by-size and --partial-special options. Signed-off-by: Jeff Hostetler --- t/5316-pack-objects-partial.sh | 72 ++ 1 file

Re: fatal: Could not get current working directory: Permission denied | affected 2.10,2.11,2.12, but not 1.9.5 |

2017-03-08 Thread René Scharfe
Am 06.03.2017 um 17:10 schrieb Zenobiusz Kunegunda: OS: FreeBSD 10.3-STABLE Story: I was trying to install openproject using this manual https://www.openproject.org/open-source/download/manual-installation-guide/ Everything was fine till command $ bundle install --deployment --without

[PATCH 00/10] RFC Partial Clone and Fetch

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler [RFC] Partial Clone and Fetch = This is a WIP RFC for a partial clone and fetch feature wherein the client can request that the server omit various blobs from the packfile during clone and fetch. Clients can later

[PATCH 05/10] fetch-pack: add partial-by-size and partial-special

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler Teach fetch-pack to take --partial-by-size and --partial-special arguments and pass them via the transport to upload-pack to request that certain blobs be omitted from the resulting packfile. Signed-off-by: Jeff Hostetler ---

[PATCH 07/10] index-pack: add --allow-partial option to relax blob existence checks

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler Teach index-pack to optionally not complain when there are missing blobs. This is for use following a partial clone or fetch when the server omitted certain blobs. Signed-off-by: Jeff Hostetler --- builtin/index-pack.c | 20

[PATCH 02/10] pack-objects: add --partial-by-size=n --partial-special

2017-03-08 Thread Jeff Hostetler
From: Jeff Hostetler Teach pack-objects to omit blobs from the generated packfile. When the --partial-by-size=n[kmg] argument is used, only blobs smaller than the requested size are included. When n is zero, no blobs are included. When the --partial-special argument is

Re: Crash on MSYS2 with GIT_WORK_TREE

2017-03-08 Thread Junio C Hamano
Johannes Schindelin writes: > Rather than a heavy-handed reversal, I would really prefer to perform a > diligent audit of all real_pathdup() callers and adjust them > appropriately. > > Turns out that the canonicalize_ceiling_entry() caller is *the only one* >

Re: [PATCH v3 0/9] Fix the early config

2017-03-08 Thread Junio C Hamano
Jeff King writes: > Good catch. Another "non-gentle" thing I noticed here while looking at > another thread: the repository-format version check uses the config > parser, which will die() in certain circumstances. So for instance: > > $ git init > $ git rev-parse && echo ok >

Re: [PATCH 4/6] send-pack: improve unpack-status error messages

2017-03-08 Thread Junio C Hamano
Jeff King writes: >> > And finally, neither message was marked for translation. The >> > message from the remote probably won't be translated, but >> > there's no reason we can't do better for the local half. >> >> Hmm, OK. > > I'll admit that I don't actually use the

Re: [PATCH v3 0/9] Fix the early config

2017-03-08 Thread Johannes Schindelin
Hi Peff, On Wed, 8 Mar 2017, Jeff King wrote: > Another "non-gentle" thing I noticed here while looking at > another thread: the repository-format version check uses the config > parser, which will die() in certain circumstances. [...] Yes, that is part of the reason why I was not eager to add

Re: [PATCH 0/2] Fix crashes due to real_pathdup() potentially returning NULL

2017-03-08 Thread Jeff King
On Wed, Mar 08, 2017 at 04:43:27PM +0100, Johannes Schindelin wrote: > We may want to consider fast-tracking this into v2.12.1, and to that > end, I would appreciate code reviews that focus on the correctness of > this patch and that try to consider undesired side effects. I don't see how it

Re: diff.ignoreSubmoudles config setting broken?

2017-03-08 Thread Sebastian Schuberth
On Wed, Mar 8, 2017 at 2:33 PM, Jeff King wrote: >> I'm getting >> >> $ git config --global diff.ignoreSubmodules all >> $ git diff >> diff --git a/scanners/scancode-toolkit b/scanners/scancode-toolkit >> index 65e5c9c..6b021a8 16 >> --- a/scanners/scancode-toolkit >> +++

[PATCH 1/2] Demonstrate NULL pointer access with invalid GIT_WORK_TREE

2017-03-08 Thread Johannes Schindelin
When GIT_WORK_TREE does not specify a valid path, we should error out. Not crash. Signed-off-by: Johannes Schindelin --- t/t1501-work-tree.sh | 8 1 file changed, 8 insertions(+) diff --git a/t/t1501-work-tree.sh b/t/t1501-work-tree.sh index

[PATCH 2/2] Fix callsites of real_pathdup() that wanted it to die on error

2017-03-08 Thread Johannes Schindelin
In 4ac9006f832 (real_path: have callers use real_pathdup and strbuf_realpath, 2016-12-12), we changed the xstrdup(real_path()) pattern to use real_pathdup() directly. The only problem with this change is that real_path() calls strbuf_realpath() with die_on_error = 1 while real_pathdup() calls it

Re: [PATCH] t2027: avoid using pipes

2017-03-08 Thread Jon Loeliger
So, like, Prathamesh Chavan said: > The exit code of the upstream of a pipe is ignored thus we should avoid > using it. By writing out the output of the git command to a file, we > can test the exit codes of both the commands. > > Signed-off-by: Prathamesh > --- >

[PATCH 0/2] Fix crashes due to real_pathdup() potentially returning NULL

2017-03-08 Thread Johannes Schindelin
This problem was identified as the root cause for what seemed to be a path conversion problem in the MSYS2 runtime at first glance. Original bug report: http://public-inbox.org/git/cafkrc7y_kpcgnorenuz2qw_4qbwjjyaadfxaeqa52ftryj+...@mail.gmail.com/ We may want to consider fast-tracking this into

Re: RFC: Another proposed hash function transition plan

2017-03-08 Thread Johannes Schindelin
Hi Ian, On Wed, 8 Mar 2017, Ian Jackson wrote: > Linus Torvalds writes ("Re: RFC: Another proposed hash function transition > plan"): > > Of course, having written that, I now realize how it would cause > > problems for the usual shit-for-brains case-insensitive filesystems. > > So I guess

Re: RFC: Another proposed hash function transition plan

2017-03-08 Thread Johannes Schindelin
Hi Ian, On Wed, 8 Mar 2017, Ian Jackson wrote: > Few people use uppercase in ref names because of the case-insensitive > filesystem problem; Not true. Ciao, Johannes

Re: Crash on MSYS2 with GIT_WORK_TREE

2017-03-08 Thread Johannes Schindelin
Hi Junio, On Tue, 7 Mar 2017, Junio C Hamano wrote: > Junio C Hamano writes: > > > OK, so it appears that we'd better audit all the callsites of > > real_pathdup() and see if anybody _assumes_ that the return values are > > not NULL. They all need fixing. Indeed. > I just

Re: diff.ignoreSubmoudles config setting broken?

2017-03-08 Thread Sebastian Schuberth
On Wed, Mar 8, 2017 at 3:01 PM, Jeff King wrote: >> > Hrm. Isn't "all" the default? That's what git-diff(1) says (but I've >> > never used the feature myself). >> > >> > That would imply to me that there's another config option set somewhere >> > (perhaps in the repo-level

Re: [PATCH] t*: avoid using pipes

2017-03-08 Thread Prathamesh Chavan
On Wed, Mar 8, 2017 at 11:33 AM, Jeff King wrote: > On Tue, Mar 07, 2017 at 12:52:49PM -0800, Stefan Beller wrote: > >> On Tue, Mar 7, 2017 at 12:39 PM, Johannes Sixt wrote: >> >> > Welcome to the Git community! >> >> > >> > Actually, being a *micro* project, it

Re: diff.ignoreSubmoudles config setting broken?

2017-03-08 Thread Jeff King
On Wed, Mar 08, 2017 at 02:43:00PM +0100, Sebastian Schuberth wrote: > > Hrm. Isn't "all" the default? That's what git-diff(1) says (but I've > > never used the feature myself). > > > > That would imply to me that there's another config option set somewhere > > (perhaps in the repo-level config).

Re: diff.ignoreSubmoudles config setting broken?

2017-03-08 Thread Jeff King
On Wed, Mar 08, 2017 at 01:54:02PM +0100, Sebastian Schuberth wrote: > I'm getting > > $ git config --global diff.ignoreSubmodules all > $ git diff > diff --git a/scanners/scancode-toolkit b/scanners/scancode-toolkit > index 65e5c9c..6b021a8 16 > --- a/scanners/scancode-toolkit > +++

Re: [PATCH v3 0/9] Fix the early config

2017-03-08 Thread Jeff King
On Tue, Mar 07, 2017 at 03:31:43PM +0100, Johannes Schindelin wrote: > > /* > >* Find GIT_DIR of the repository that contains the current working > >* directory, without changing the working directory or other global > >* state. The result is appended to gitdir. The return value is

diff.ignoreSubmoudles config setting broken?

2017-03-08 Thread Sebastian Schuberth
Hi, with $ git --version git version 2.12.0.windows.1 I'm getting $ git config --global diff.ignoreSubmodules all $ git diff diff --git a/scanners/scancode-toolkit b/scanners/scancode-toolkit index 65e5c9c..6b021a8 16 --- a/scanners/scancode-toolkit +++ b/scanners/scancode-toolkit @@ -1 +1

Re: RFC: Another proposed hash function transition plan

2017-03-08 Thread Ian Jackson
Linus Torvalds writes ("Re: RFC: Another proposed hash function transition plan"): > Also, since 256 isn't evenly divisible by 6, and because you'd want > some way to explictly disambiguate the new hashes, the rule *could* be > that the ASCII representation of a new hash is the base64 encoding of

Re: [PATCH 4/6] send-pack: improve unpack-status error messages

2017-03-08 Thread Jeff King
On Tue, Mar 07, 2017 at 02:56:27PM -0800, Junio C Hamano wrote: > Jeff King writes: > > > When the remote tells us that the "unpack" step failed, we > > show an error message. However, unless you are familiar with > > the internals of send-pack and receive-pack, it was not > >

Re: Crash on MSYS2 with GIT_WORK_TREE

2017-03-08 Thread Johannes Schindelin
Hi valtron, On Tue, 7 Mar 2017, valtron wrote: > I only ran into this because of git-gui, where I eventually tracked it > down to line 1330: > > set env(GIT_WORK_TREE) $_gitworktree As git-gui is a Tcl script, which in turn runs as a pure Windows application, the path should use

Re: Crash on MSYS2 with GIT_WORK_TREE

2017-03-08 Thread Johannes Schindelin
Hi Brandon, On Tue, 7 Mar 2017, Brandon Williams wrote: > On 03/08, Johannes Schindelin wrote: > > > > [...] On *Linux*, this happens: > > > > $ GIT_WORK_TREE=c:/invalid git rev-parse HEAD > > Segmentation fault (core dumped) > > > > The reason is this: when set_git_work_tree() was

[PATCH] diff: allow "-" as a short-hand for "last branch"

2017-03-08 Thread mash
Just like "git merge -" is a short-hand for "git merge @{-1}" to conveniently merge the previous branch, "git diff -" is a short-hand for "git diff @{-1}" to conveniently diff against the previous branch. Allow the usage of "-" in the dot dot notation to allow the use of "git diff -..HEAD^" as a

<    1   2