Re: git diff does not precompose unicode file paths (OS X)

2016-03-06 Thread Alexander Rinass
> On 04 Mar 2016, at 19:49, Ramsay Jones wrote: > > > > On 04/03/16 14:37, Alexander Rinass wrote: >> >>> On 04 Mar 2016, at 13:16, Torsten Bögershausen wrote: >>> >>> On 03/04/2016 10:07 AM, Alexander Rinass wrote: > [snip] > >> >> Sticking a precompose_argv(argc, argv) into diff.c’s cmd

Re: Resumable clone

2016-03-06 Thread Junio C Hamano
Johannes Schindelin writes: > First of all: my main gripe with the discussed approach is that it uses > bundles. I know, I introduced bundles, but they just seem too klunky and > too static for the resumable clone feature. We should make the mechanism extensible so that we can later support mult

Re: [PATCH v2 1/2] mergetool: honor tempfile configuration when resolving delete conflicts

2016-03-06 Thread Junio C Hamano
David Aguilar writes: > Teach resolve_deleted_merge() to honor the mergetool.keepBackup and > mergetool.keepTemporaries configuration knobs. > > This ensures that the worktree is kept pristine when resolving deletion > conflicts with the variables both set to false. > > Signed-off-by: David Aguil

Re: [RFC/PATCH] clone: make 'git clone -c remote.origin.fetch=' work

2016-03-06 Thread Junio C Hamano
SZEDER Gábor writes: > Check whether there are any relevant configured fetch refspecs and > take those into account during the initial fetch, unless running 'git > clone --single-branch'. > > Signed-off-by: SZEDER Gábor > --- Even though I think the original description did not mean to include

Re: [PATCH 5/6] grep: turn off gitlink detection for --no-index

2016-03-06 Thread Junio C Hamano
Jeff King writes: > If we are running "git grep --no-index" outside of a git > repository, we behave roughly like "grep -r", examining all > files in the current directory and its subdirectories. > However, because we use fill_directory() to do the > recursion, it will skip over any directories w

Re: [PATCH 6/6] use setup_git_directory() in test-* programs

2016-03-06 Thread Junio C Hamano
Jeff King writes: > Some of the test-* programs rely on examining refs, but did > not bother to make sure we are actually in a git repository. > Let's have them call setup_git_directory() to do so. > > Signed-off-by: Jeff King > --- > As discussed elsewhere, test-match-trees isn't actually used

[RFC/PATCH] clone: make 'git clone -c remote.origin.fetch=' work

2016-03-06 Thread SZEDER Gábor
Configuration variables specified via 'git clone -c =' "take effect immediately after the repository is initialized, but before the remote history is fetched". This implies that any fetch refspecs specified this way should already be taken into account during the initial fetch and remote refs matc

Re: [PATCH] fetch: show reference pointed by new tags

2016-03-06 Thread Junio C Hamano
Junio C Hamano writes: >> This is my first dive into git's code, so it's likely I'm not doing things >> right. The first candidate for that is the literal `7`,... Actually, the first candidate is not related to any code, but that you did not explain "why" in your log message. I raised two issue

Re: [PATCH] fetch: show reference pointed by new tags

2016-03-06 Thread Junio C Hamano
Eric Engestrom writes: > Before, new tags had their names shown twice: > * [new tag] v4.5-rc6 -> v4.5-rc6 > > Instead, show the hash of the commit pointed to: > * [new tag] v4.5-rc6 -> fc77dbd > > Signed-off-by: Eric Engestrom The report from update-local-refs is meant to

[PATCH v2 2/4] t6302: normalize names and descriptions of signed tags

2016-03-06 Thread Eric Sunshine
An upcoming patch will increase test coverage by testing annotated but not signed tags, as well, so normalize names and descriptions of signed tags to make it easy to give the upcoming unsigned tags similarly patterned names and descriptions. Signed-off-by: Eric Sunshine --- t/t6302-for-each-ref

[PATCH v2 3/4] t6302: also test annotated in addition to signed tags

2016-03-06 Thread Eric Sunshine
It is conceivable, if not highly plausible, that a change to the git-for-each-ref code that does the filtering and formatting can become buggy because a payload with GPG signature looks somewhat different from what is in an annotated but not signed tag. Thus, let's test unsigned tags, as well. Sig

[PATCH v2 4/4] t6302: skip only signed tags rather than all tests when GPG is missing

2016-03-06 Thread Eric Sunshine
The primary purpose of these tests is to check filtering, sorting, and formatting behavior of git-for-each-ref, so it is unfortunate that the entire test script is skipped when GPG is not present. Rather than skipping all tests, let's instead just skip testing against signed tags when GPG is missin

[PATCH v2 1/4] lib-gpg: drop unnecessary "missing GPG" warning

2016-03-06 Thread Eric Sunshine
When 37d3e85 (t7004: factor out gpg setup, 2011-09-07) pulled gpg detection code out of t7004-tag.sh and turned it into a standard test prerequisite, it added an unconditional "missing GPG" warning when gpg is not detected. However, this is redundant since all tests which require GPG already warn

[PATCH v2 0/4] make t6302 usable even without GPG installed

2016-03-06 Thread Eric Sunshine
This is a re-roll of [1] which aims to allow t6302 to be run even without GPG installed. Changes since v1: * rather than converting existing signed tags to unsigned, make testing of unsigned tags a normal part of the script and just suppress testing of signed tags when GPG is missing (Junio)

[PATCH] fetch: show reference pointed by new tags

2016-03-06 Thread Eric Engestrom
Before, new tags had their names shown twice: * [new tag] v4.5-rc6 -> v4.5-rc6 Instead, show the hash of the commit pointed to: * [new tag] v4.5-rc6 -> fc77dbd Signed-off-by: Eric Engestrom --- This is my first dive into git's code, so it's likely I'm not doing things righ

Re: [PATCH] Allow "-" as a short-hand for "@{-1}" in "git branch -d @{-1}"

2016-03-06 Thread Junio C Hamano
Eric Sunshine writes: >> + if (argc == 3 && !strcmp(argv[2], "-")) > ... > To address these issues, it seems like a more correct place to > recognize "-" as an alias would be somewhere within > builtin/branch.d:delete_branches(). I agree with all your review comments, and the above would a

Re: Resumable clone

2016-03-06 Thread Junio C Hamano
Duy Nguyen writes: > One thing Junio didn't mention in his summary is the use of pack > bitmap [1]. Jeff talked about GitHub specific needs,... Do not take it as the "summary of the whole discussion". I deliberately tried to limit the list to absolute minimum to allow building a workable initia

Re: [PATCH] Allow "-" as a short-hand for "@{-1}" in "git branch -d @{-1}"

2016-03-06 Thread Eric Sunshine
On Sun, Mar 6, 2016 at 7:48 AM, Dinesh Polathula wrote: > From: Dinesh You can drop this line and let git-am pick up your name and address from the email envelope. > Allow "-" as a short-hand for "@{-1}" in "git branch -d @{-1}" branch: -d/-D: recognize "-" as short-hand for @{-1} > The "

Re: Fsck configurations and cloning.

2016-03-06 Thread Jeff King
On Sun, Mar 06, 2016 at 10:38:15AM -0500, Ryne Everett wrote: > > I think there are two problems here. > > > > The first is that fsck.skiplist takes a filename that contains a list of > > sha1s, not the sha1s themselves. So it would be more like: > > > > echo 5e6ecdad9f69b1ff789a17733b8edc6fd709

Re: Fsck configurations and cloning.

2016-03-06 Thread Ryne Everett
> I think there are two problems here. > > The first is that fsck.skiplist takes a filename that contains a list of > sha1s, not the sha1s themselves. So it would be more like: > > echo 5e6ecdad9f69b1ff789a17733b8edc6fd7091bd8 >skiplist > git -c fsck.skiplist="$(pwd)/skiplist" clone ... I thin

Re: Fsck configurations and cloning.

2016-03-06 Thread Ryne Everett
> You have to make sure the fields are set within a global git > configuration. Did you set this within a previous clone using "git > config"? If so you need to make sure you use "--global" option to > write it to your user configuration file so that it is persistent > across multiple repositories.

(Re: MUTUAL BENEFIT!!!)

2016-03-06 Thread Mr. Marco Hellman
From: Integrated Crystal Investment Company 30th Floor Millbank Tower 21-24 Millbank London SW1P 4QP Dear Sir, I got your contact from my Google research. I trust my instinct and my instinct has never failed me in the past. I am convinced that you are the person who can assist me in this pend

[PATCH] Allow "-" as a short-hand for "@{-1}" in "git branch -d @{-1}"

2016-03-06 Thread Dinesh Polathula
From: Dinesh The "-" shorthand can be used as a replacement for "@{-1}" to refer to the previous branch the user was on in the "git branch -d @{-1}" command. Replace "-" argument with "@{-1}" when the command line arguments are parsed. Signed-off-by: Dinesh Polathula --- builtin/branch.c | 11 +

[PATCH] Allow "-" as a short-hand for "@{-1}" in "git branch -d @{-1}"

2016-03-06 Thread Dinesh Polathula
From: Dinesh This patch allows the usage of "-" as a short-hand for "@{-1}" in "git branch -d {-1}". Note : This is a microproject that is part of the Google Summer of Code application process. I am interested in working on the git Beginner mode implementation as part of Google Summer of Co

[PATCH 08/15] ref-filter: make "%(symref)" atom work with the ':short' modifier

2016-03-06 Thread Karthik Nayak
The "%(symref)" atom doesn't work when used with the ':short' modifier because we strictly match only 'symref' for setting the 'need_symref' indicator. Fix this by using 'starts_with()' rather than 'strcmp()'. Add tests for %(symref) and %(symref:short) while we're here. Signed-off-by: Karthik Na

[PATCH 13/15] branch, tag: use porcelain output

2016-03-06 Thread Karthik Nayak
Call ref-filter's setup_ref_filter_porcelain_msg() to enable translated messages for the %(upstream:tack) atom. Although branch.c doesn't currently use ref-filter's printing API's, this will ensure that when it does in the future patches, we do not need to worry about translation. Written-by: Matt

[PATCH 15/15] branch: implement '--format' option

2016-03-06 Thread Karthik Nayak
Implement the '--format' option provided by 'ref-filter'. This lets the user list tags as per desired format similar to the implementation in 'git for-each-ref'. Add tests and documentation for the same. Mentored-by: Christian Couder Mentored-by: Matthieu Moy Signed-off-by: Karthik Nayak ---

[PATCH 14/15] branch: use ref-filter printing APIs

2016-03-06 Thread Karthik Nayak
Port branch.c to use ref-filter APIs for printing. This clears out most of the code used in branch.c for printing and replaces them with calls made to the ref-filter library. Introduce build_format() which gets the format required for printing of refs. Make amendments to print_ref_list() to reflec

[PATCH 07/15] ref-filter: add support for %(upstream:track,nobracket)

2016-03-06 Thread Karthik Nayak
Add support for %(upstream:track,nobracket) which will print the tracking information without the brackets (i.e. "ahead N, behind M"). This is needed when we port branch.c to use ref-filter's printing APIs. Add test and documentation for the same. Mentored-by: Christian Couder Mentored-by: Matth

[PATCH 10/15] ref-filter: introduce refname_atom_parser()

2016-03-06 Thread Karthik Nayak
Introduce refname_atom_parser() which will parse the '%(refname)' atom and store information into the 'used_atom' structure based on the modifiers used along with the atom. Signed-off-by: Karthik Nayak --- ref-filter.c | 70 +--- 1 file cha

[PATCH 06/15] ref-filter: make %(upstream:track) prints "[gone]" for invalid upstreams

2016-03-06 Thread Karthik Nayak
Borrowing from branch.c's implementation print "[gone]" whenever an unknown upstream ref is encountered instead of just ignoring it. This makes sure that when branch.c is ported over to using ref-filter APIs for printing, this feature is not lost. Make changes to t/t6300-for-each-ref.sh to reflec

[PATCH 11/15] ref-filter: add support for %(refname:dir) and %(refname:base)

2016-03-06 Thread Karthik Nayak
Add the options `:dir` and `:base` to the %(refname) atom. The `:dir` option gives the directory (the part after $GIT_DIR/) of the ref without the refname. The `:base` option gives the base directory of the given ref (i.e. the directory following $GIT_DIR/refs/). Add tests and documentation for th

[PATCH 12/15] ref-filter: allow porcelain to translate messages in the output

2016-03-06 Thread Karthik Nayak
Introduce setup_ref_filter_porcelain_msg() so that the messages used in the atom %(upstream:track) can be translated if needed. This is needed as we port branch.c to use ref-filter's printing API's. Written-by: Matthieu Moy Mentored-by: Christian Couder Mentored-by: Matthieu Moy Signed-off-by:

[PATCH 09/15] ref-filter: introduce symref_atom_parser()

2016-03-06 Thread Karthik Nayak
Introduce symref_atom_parser() which will parse the '%(symref)' atom and store information into the 'used_atom' structure based on the modifiers used along with the atom. Signed-off-by: Karthik Nayak --- ref-filter.c | 26 -- 1 file changed, 24 insertions(+), 2 deletions(

[PATCH 05/15] ref-filter: introduce format_ref_array_item()

2016-03-06 Thread Karthik Nayak
To allow column display, we will need to first render the output in a string list to allow print_columns() to compute the proper size of each column before starting the actual output. Introduce the function format_ref_array_item() that does the formatting of a ref_array_item to an strbuf. show_ref

[PATCH 01/15] ref-filter: implement %(if), %(then), and %(else) atoms

2016-03-06 Thread Karthik Nayak
Implement %(if), %(then) and %(else) atoms. Used as %(if)...%(then)...%(end) or %(if)...%(then)...%(else)...%(end). If the format string between %(if) and %(then) expands to an empty string, or to only whitespaces, then the whole %(if)...%(end) expands to the string following %(then). Otherwise, it

[PATCH 04/15] ref-filter: move get_head_description() from branch.c

2016-03-06 Thread Karthik Nayak
Move the implementation of get_head_description() from branch.c to ref-filter. This gives a description of the HEAD ref if called. This is used as the refname for the HEAD ref whenever the FILTER_REFS_DETACHED_HEAD option is used. Make it public because we need it to calculate the length of the HE

[PATCH 02/15] ref-filter: implement %(if:equals=) and %(if:notequals=)

2016-03-06 Thread Karthik Nayak
Implement %(if:equals=) wherein the if condition is only satisfied if the value obtained between the %(if:...) and %(then) atom is the same as the given ''. Similarly, implement (if:notequals=) wherein the if condition is only satisfied if the value obtained between the %(if:...) and %(then) atom

[PATCH 03/15] ref-filter: modify "%(objectname:short)" to take length

2016-03-06 Thread Karthik Nayak
Add support for %(objectname:short=) which would print the abbreviated unique objectname of given length. When no length is specified 7 is used. The minimum length is 'MINIMUM_ABBREV'. Add tests and documentation for the same. Mentored-by: Christian Couder Mentored-by: Matthieu Moy Signed-off-b

[PATCH 00/15] port branch.c to use ref-filter's printing options

2016-03-06 Thread Karthik Nayak
This is part of unification of the commands 'git tag -l, git branch -l and git for-each-ref'. This ports over branch.c to use ref-filter's printing options. Initially posted here: $(gmane/279226). It was decided that this series would follow up after refactoring ref-filter parsing mechanism, which

Re: Fsck configurations and cloning.

2016-03-06 Thread Jeff King
On Sat, Mar 05, 2016 at 08:44:38PM -0500, Ryne Everett wrote: > I'm assuming fsck configurations are supposed to apply to clones but > I'm having no luck: > > $ git --version > git version 2.7.2 > $ git config --get transfer.fsckobjects > true > $ git config --get fsck.badTime

Re: Resumable clone

2016-03-06 Thread Duy Nguyen
On Sun, Mar 6, 2016 at 3:49 PM, Duy Nguyen wrote: > One thing Junio didn't mention in his summary is the use of pack > bitmap [1]. > > [1] http://thread.gmane.org/gmane.comp.version-control.git/288205/focus=288222 Oops, wrong link. Should be this one http://article.gmane.org/gmane.comp.vers

Re: Resumable clone

2016-03-06 Thread Duy Nguyen
On Sun, Mar 6, 2016 at 2:59 PM, Johannes Schindelin wrote: > First of all: my main gripe with the discussed approach is that it uses > bundles. I know, I introduced bundles, but they just seem too klunky and > too static for the resumable clone feature. One thing Junio didn't mention in his summa