git checkout resets modified files

2015-08-29 Thread Steve Heyns
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 languages are similar) if you execute a

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

Re: git checkout resets modified files

2015-08-29 Thread Junio C Hamano
Steve Heyns notzi...@gmail.com 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

Re: git checkout resets modified files

2015-08-29 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com 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

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

[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

[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 `:width,position`, where the `position` is either left, right or middle and `width` is the size of the area into which the content will be placed. If the content between

[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 '-nnum' 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

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

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak karthik@gmail.com 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

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

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak karthik@gmail.com 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.

[PATCH v14 11/13] tag.c: use 'ref-filter' APIs

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak karthik@gmail.com 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

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

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak karthik@gmail.com 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

[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 sunsh...@sunshineco.com Mentored-by: Christian Couder christian.cou...@gmail.com

[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

[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 sunsh...@sunshineco.com Mentored-by: Christian Couder christian.cou...@gmail.com Mentored-by: Matthieu Moy matthieu@grenoble-inp.fr Signed-off-by: Karthik

[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

[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

[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 christian.cou...@gmail.com Mentored-by: Matthieu Moy

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

2015-08-29 Thread Philip Oakley
From: Alex Henrie alexhenri...@gmail.com Signed-off-by: Alex Henrie alexhenri...@gmail.com --- 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 +++

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 p...@peff.net wrote: On

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 ber...@primeranks.net wrote: Hello, Here's what I ended up using, and seemed to work well:

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

2015-08-29 Thread Karthik Nayak
From: Karthik Nayak karthik@gmail.com 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

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 gits...@pobox.com wrote: Namhyung Kim namhy...@gmail.com 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

[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

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 enum { +

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 tbo...@web.de 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

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 philipoak...@iee.org: 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

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 karthik@gmail.com 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

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 sunsh...@sunshineco.com

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

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 ber...@primeranks.net 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

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 karthik@gmail.com 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

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 karthik@gmail.com wrote: Implement an `align` atom which left-, middle-, or right-aligns the content between %(align:..) and %(end). It is followed by `:width,position`, where the `position` is either left, right or middle and `width` is the

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 ber...@primeranks.net 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))