Re: [PATCH v14 05/13] ref-filter: add option to filter out tags, branches and remotes

2015-08-29 Thread Karthik Nayak
On Sun, Aug 30, 2015 at 9:00 AM, Eric Sunshine wrote: > On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: >> Add a function called 'for_each_fullref_in()' to refs.{c,h} which >> iterates through each ref for the given path without trimming the path >> and also accounting for broken refs, if

Re: [PATCH v14 06/13] ref-filter: introduce format_ref_array_item()

2015-08-29 Thread Karthik Nayak
On Sun, Aug 30, 2015 at 9:12 AM, Eric Sunshine wrote: > On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: >> Create format_ref_array_item() out of show_ref_array_item(). This will >> store the output format for the given ref_array_item into the provided >> strbuf. Make show_ref_array_item()

Re: [PATCH v14 06/13] ref-filter: introduce format_ref_array_item()

2015-08-29 Thread Karthik Nayak
On Sun, Aug 30, 2015 at 9:12 AM, Eric Sunshine wrote: > On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: >> Create format_ref_array_item() out of show_ref_array_item(). This will >> store the output format for the given ref_array_item into the provided >> strbuf. Make show_ref_array_item()

Re: [PATCH v4 2/4] path: optimize common dir checking

2015-08-29 Thread Torsten Bögershausen
On 26.08.15 21:46, David Turner wrote: > Instead of a linear search over common_list to check whether > a path is common, use a trie. The trie search operates on > path prefixes, and handles excludes. > > Signed-off-by: David Turner > --- > path.c| 226 > +++

git bisect replay produces wrong result

2015-08-29 Thread Neil Brown
Hi, the following git-bisect log - applied to a recent linux-kernel tree produced different end results when I use "git bisect replay" and when I just run it as a shell script. $ git bisect replay /tmp/log We are not bisecting. Bisecting: a merge base must be tested [2decb2682f80759f631c8332f

Re: [PATCH v14 06/13] ref-filter: introduce format_ref_array_item()

2015-08-29 Thread Eric Sunshine
On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: > Create format_ref_array_item() out of show_ref_array_item(). This will > store the output format for the given ref_array_item into the provided > strbuf. Make show_ref_array_item() a wrapper around this to print the > given ref_array_item wi

Re: [PATCH v14 05/13] ref-filter: add option to filter out tags, branches and remotes

2015-08-29 Thread Eric Sunshine
On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: > Add a function called 'for_each_fullref_in()' to refs.{c,h} which > iterates through each ref for the given path without trimming the path > and also accounting for broken refs, if mentioned. > > Add 'filter_ref_kind()' in ref-filter.c to ch

Re: [PATCH v14 04/13] ref-filter: implement an `align` atom

2015-08-29 Thread Eric Sunshine
On Sat, Aug 29, 2015 at 10:12 AM, Karthik Nayak wrote: > Implement an `align` atom which left-, middle-, or right-aligns the > content between %(align:..) and %(end). > > It is followed by `:,`, where the `` is > either left, right or middle and `` is the size of the area > into which the content

Re: [FEATURE REQUEST] Filter-branch extend progress with a simple estimated time remaning

2015-08-29 Thread Eric Sunshine
(Please don't top-post on this list.) On Sat, Aug 29, 2015 at 11:00 PM, Gabor Bernat wrote: > Reading after it, I think the most close we can get with this is, awk > 'BEGIN { print strftime("%c", 1271603087); }; and just ignore setting > this value (and avoid displaying it) if that fails too. Do

Re: [FEATURE REQUEST] Filter-branch extend progress with a simple estimated time remaning

2015-08-29 Thread Gabor Bernat
Reading after it, I think the most close we can get with this is, awk 'BEGIN { print strftime("%c", 1271603087); }; and just ignore setting this value (and avoid displaying it) if that fails too. Do you agree? Bernát GÁBOR On Sun, Aug 30, 2015 at 3:20 AM, Eric Sunshine wrote: > On Sat, Aug 29, 2

Re: [FEATURE REQUEST] Filter-branch extend progress with a simple estimated time remaning

2015-08-29 Thread Eric Sunshine
On Sat, Aug 29, 2015 at 9:29 AM, Gabor Bernat wrote: > Amended, the latest version is at https://github.com/gaborbernat/git/commit/ > :) > Does this looks okay, should I create a patch from this? Excerpt: now=$(date +%s) elapsed=$(($now - $start)) remaining_second=$((...)) eta=$

Re: [PATCH] show-ref: place angle brackets around variables in usage string

2015-08-29 Thread Alex Henrie
2015-08-29 4:21 GMT-06:00 Philip Oakley : > Should the '<' stdin redirection be shown? > > It looks (at first glance) as if this gained a double '< <' at the beginning > of 'ref-list', rather than being a clean indication of the redirection. > Perhaps change 'ref-list' to 'ref-list-file' for a slig

Re: [PATCH v14 03/13] utf8: add function to align a string into given strbuf

2015-08-29 Thread Karthik Nayak
On Sat, Aug 29, 2015 at 10:40 PM, Torsten Bögershausen wrote: > On 29.08.15 16:12, Karthik Nayak wrote: >> diff --git a/utf8.h b/utf8.h >> index 5a9e94b..7930b44 100644 >> --- a/utf8.h >> +++ b/utf8.h >> @@ -55,4 +55,19 @@ int mbs_chrlen(const char **text, size_t *remainder_p, >> const char *enco

Re: [PATCH v14 03/13] utf8: add function to align a string into given strbuf

2015-08-29 Thread Torsten Bögershausen
On 29.08.15 16:12, Karthik Nayak wrote: > diff --git a/utf8.h b/utf8.h > index 5a9e94b..7930b44 100644 > --- a/utf8.h > +++ b/utf8.h > @@ -55,4 +55,19 @@ int mbs_chrlen(const char **text, size_t *remainder_p, > const char *encoding); > */ > int is_hfs_dotgit(const char *path); > > +typedef en

[PATCH v3] stash: Add two config variables for stash show

2015-08-29 Thread Namhyung Kim
Some users might want to see diff (patch) output always rather than diffstat when [s]he runs 'git stash show'. Although this can be done with adding -p option, it'd be better to provide a config option to control this behavior IMHO. This patch adds two variables which control to show diffstat and

Re: [PATCH] stash: Add stash.showFlag config variable

2015-08-29 Thread Namhyung Kim
Hi, On Sat, Aug 29, 2015 at 3:10 AM, Junio C Hamano wrote: > Namhyung Kim writes: > >>> Perhaps a pair of new booleans >>> >>> - stash.showStat (defaults to true but you can turn it off) >>> - stash.showPatch (defaults to false but you can turn it on) >>> >>> or something along that line might

[PATCH v14 13/13] tag.c: implement '--merged' and '--no-merged' options

2015-08-29 Thread Karthik Nayak
Use 'ref-filter' APIs to implement the '--merged' and '--no-merged' options into 'tag.c'. The '--merged' option lets the user to only list tags merged into the named commit. The '--no-merged' option lets the user to only list tags not merged into the named commit. If no object is provided it assum

[PATCH v14 04/13] ref-filter: implement an `align` atom

2015-08-29 Thread Karthik Nayak
Implement an `align` atom which left-, middle-, or right-aligns the content between %(align:..) and %(end). It is followed by `:,`, where the `` is either left, right or middle and `` is the size of the area into which the content will be placed. If the content between %(align:) and %(end) is more

[PATCH v14 07/13] ref-filter: add support for %(contents:lines=X)

2015-08-29 Thread Karthik Nayak
In 'tag.c' we can print N lines from the annotation of the tag using the '-n' option. Copy code from 'tag.c' to 'ref-filter' and modify it to support appending of N lines from the annotation of tags to the given strbuf. Implement %(contents:lines=X) where X lines of the given object are obtained.

[PATCH v14 08/13] ref-filter: add support to sort by version

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak Add support to sort by version using the "v:refname" and "version:refname" option. This is achieved by using the 'versioncmp()' function as the comparing function for qsort. This option is included to support sorting by versions in `git tag -l` which will eventually be ported

[PATCH v14 10/13] tag.c: use 'ref-filter' data structures

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak Make 'tag.c' use 'ref-filter' data structures and make changes to support the new data structures. This is a part of the process of porting 'tag.c' to use 'ref-filter' APIs. This is a temporary step before porting 'tag.c' to use 'ref-filter' completely. As this is a temporary

[PATCH v14 09/13] ref-filter: add option to match literal pattern

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak Since 'ref-filter' only has an option to match path names add an option for plain fnmatch pattern-matching. This is to support the pattern matching options which are used in `git tag -l` and `git branch -l` where we can match patterns like `git tag -l foo*` which would match

[PATCH v14 06/13] ref-filter: introduce format_ref_array_item()

2015-08-29 Thread Karthik Nayak
Create format_ref_array_item() out of show_ref_array_item(). This will store the output format for the given ref_array_item into the provided strbuf. Make show_ref_array_item() a wrapper around this to print the given ref_array_item with linefeed. Mentored-by: Christian Couder Mentored-by: Matthi

[PATCH v14 12/13] tag.c: implement '--format' option

2015-08-29 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 v14 11/13] tag.c: use 'ref-filter' APIs

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak Make 'tag.c' use 'ref-filter' APIs for iterating through refs, sorting and printing of refs. This removes most of the code used in 'tag.c' replacing it with calls to the 'ref-filter' library. Make 'tag.c' use the 'filter_refs()' function provided by 'ref-filter' to filter out

[PATCH v14 03/13] utf8: add function to align a string into given strbuf

2015-08-29 Thread Karthik Nayak
Add strbuf_utf8_align() which will align a given string into a strbuf as per given align_type and width. If the width is greater than the string length then no alignment is performed. Helped-by: Eric Sunshine Mentored-by: Christian Couder Mentored-by: Matthieu Moy Signed-off-by: Karthik Nayak

[PATCH v14 05/13] ref-filter: add option to filter out tags, branches and remotes

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak Add a function called 'for_each_fullref_in()' to refs.{c,h} which iterates through each ref for the given path without trimming the path and also accounting for broken refs, if mentioned. Add 'filter_ref_kind()' in ref-filter.c to check the kind of ref being handled and retur

[PATCH v14 00/13] Port tag.c to use ref-filter.c

2015-08-29 Thread Karthik Nayak
This is part of porting tag.c to ref-filter APIs. Version 13 can be found: thread.gmane.org/gmane.comp.version-control.git/276363 Changes in this version: * Introduce format_ref_array_item() and make show_ref_array_item() a wrapper around the same. * Introduce %(contents:lines=X) which gets the fi

[PATCH v14 01/13] ref-filter: move `struct atom_value` to ref-filter.c

2015-08-29 Thread Karthik Nayak
Since atom_value is only required for the internal working of ref-filter it doesn't belong in the public header. Helped-by: Eric Sunshine Mentored-by: Christian Couder Mentored-by: Matthieu Moy Signed-off-by: Karthik Nayak --- ref-filter.c | 5 + ref-filter.h | 5 + 2 files changed, 6

[PATCH v14 02/13] ref-filter: introduce ref_formatting_state and ref_formatting_stack

2015-08-29 Thread Karthik Nayak
Introduce ref_formatting_state which will hold the formatted output strbuf instead of directly printing to stdout. This will help us in creating modifier atoms which modify the format specified before printing to stdout. Implement a stack machinery for ref_formatting_state, this allows us to push

Re: [FEATURE REQUEST] Filter-branch extend progress with a simple estimated time remaning

2015-08-29 Thread Gabor Bernat
Amended, the latest version is at https://github.com/gaborbernat/git/commit/ :) Bernát GÁBOR On Sat, Aug 29, 2015 at 11:50 AM, Gabor Bernat wrote: > Hello, > > Here's what I ended up using, and seemed to work well: > https://github.com/gaborbernat/git/commit/766841bc1b726a5d6e7e051938b8297536869

Re: [PATCH] show-ref: place angle brackets around variables in usage string

2015-08-29 Thread Philip Oakley
From: "Alex Henrie" Signed-off-by: Alex Henrie --- builtin/show-ref.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/show-ref.c b/builtin/show-ref.c index dfbc314..131ef28 100644 --- a/builtin/show-ref.c +++ b/builtin/show-ref.c @@ -8,7 +8,7 @@ static const char * c

Dear Customer,

2015-08-29 Thread DHL
Please find attached your DHL air way bill tracking number Sincerely DHL Express Team --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus DHL-Tracking_Number.pdf Description: Adobe PDF document

Re: [FEATURE REQUEST] Filter-branch extend progress with a simple estimated time remaning

2015-08-29 Thread Gabor Bernat
Hello, Here's what I ended up using, and seemed to work well: https://github.com/gaborbernat/git/commit/766841bc1b726a5d6e7e051938b82975368695a0 Does this looks okay, should I create a patch from this? Thanks, Bernát GÁBOR On Wed, Aug 26, 2015 at 4:15 AM, Jeff King wrote: > On Tue, Aug 25, 20

Git crash on different versions, including current

2015-08-29 Thread Christian Soltenborn
Hi everybody, today I ran into a git issue on Windows 7/64. My directory structure looks like this, and I wondered why the content of a dir wouldn't get added. C:\Users\chris\git\GoogleTestExtension -- .git -- ConsoleApplication1 (new) - gtest-1.7.0 dir (does not get added) - stuff that h

Re: "git checkout" resets modified files

2015-08-29 Thread Junio C Hamano
Junio C Hamano writes: > I do not think this behaviour depends on the vintage of Git. An > empty string as pathspec has always matched "everything in here" > AFAIR. Having said all that, I think the DWIM used by "git checkout" has some room for improvement, namely, its "we didn't see a double-d

Re: "git checkout" resets modified files

2015-08-29 Thread Junio C Hamano
Steve Heyns writes: > "git checkout" resets modified files > > Version git 2.5.0, > > Description: > I was automating a process that would pull and switch to another > branch when I stumbled across this. I have not been able to emulate > this from command line but using go (or I imagine other la