Re: [RFC PATCH] pack-refs: fail on falsely sorted packed-refs

2019-02-22 Thread Max Kirillov
On Wed, Feb 13, 2019 at 11:56:16AM +0100, SZEDER Gábor wrote: >>> + if (iter) >>> + { > > According to our CodingGuidelines, the opening bracket should go on > the same line as the condition, i.e. > > if (iter) { Oh, thanks. I must have been professionally deformed.

Re: [RFC PATCH] pack-refs: fail on falsely sorted packed-refs

2019-02-22 Thread Max Kirillov
On Wed, Feb 13, 2019 at 11:08:01AM +0100, Ævar Arnfjörð Bjarmason wrote: > You have an extra two whitespaces after "&&" there. Thanks, will check it. >> +git commit --allow-empty -m commit && > Looks like just "test_commit A" would do here. About this I'm not sure. AFAIK test_commit does lot

[PATCH] Fix the quotation mark in the explanation of "git checkout -".

2019-02-22 Thread Yoichi Nakayama
Signed-off-by: Yoichi Nakayama --- Documentation/git-checkout.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt index 801de2f764..55eb39a897 100644 --- a/Documentation/git-checkout.txt +++ b/Documentation/git-ch

Re: .gitignore alleged bug

2019-02-22 Thread brian m. carlson
On Fri, Feb 22, 2019 at 03:39:53PM +, Celestino, Federico wrote: > Dear Support Team, > > I am facing a serious issue with .gitignore (see attachment). > > The problem is that the folder contents of 04 - Software/SW > Code/STM32/Lib/Drivers/CMSIS/Device/ are ignored because of a suspected >

Re: [PATCH] Delete check-racy.c

2019-02-22 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > This is git-checy-racy command, added a long time ago [1] and was never > part of the default build. Naturally after some makefile changes [2], > git-check-racy was no longer recognized as a build target. Even if it > compiles to day, it will not link after the int

Re: [PATCH v2 6/6] Makefile: allow for combining DEVELOPER=1 and CFLAGS="..."

2019-02-22 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > diff --git a/config.mak.dev b/config.mak.dev > index 7354fe15b3..bf1f3fcdee 100644 > --- a/config.mak.dev > +++ b/config.mak.dev > @@ -1,41 +1,41 @@ > ifeq ($(filter no-error,$(DEVOPTS)),) > -CFLAGS += -Werror > +DEVELOPER_CFLAGS += -Werror This is the first m

Re: [PATCH v2 5/6] Makefile: move the setting of *FLAGS closer to "include"

2019-02-22 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > Move the setting of variables like CFLAGS down past settings like > "prefix" and default programs like "TAR" to just before we do the > include from "config.mak.*". > > There's no functional changes here yet, but move note that > "ALL_CFLAGS" and "ALL_LDFLAGS" a

Re: [PATCH 7/8] commit-graph write: don't die if the existing graph is corrupt

2019-02-22 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > When the commit-graph is written we end up calling > parse_commit(). This will in turn invoke code that'll consult the > existing commit-graph about the commit, if the graph is corrupted we > die. Irony ;-). > Change the "commit-graph write" codepath to use a

[PATCH v7 08/15] trace2:data: add trace2 hook classification

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Classify certain child processes as hooks. Signed-off-by: Jeff Hostetler --- builtin/am.c | 1 + builtin/receive-pack.c | 4 builtin/worktree.c | 1 + sequencer.c| 2 ++ transport.c| 1 + 5 files changed, 9 insertions(+) diff --g

[PATCH v7 12/15] trace2:data: add subverb to reset command

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- builtin/reset.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/builtin/reset.c b/builtin/reset.c index 59898c972e..4e34c61401 100644 --- a/builtin/reset.c +++ b/builtin/reset.c @@ -340,6 +340,7 @@ int cmd_reset(int argc, const ch

[PATCH v7 07/15] trace2:data: add trace2 transport child classification

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add trace2 child classification for transport processes. Signed-off-by: Jeff Hostetler --- connect.c | 3 +++ transport-helper.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/connect.c b/connect.c index 24281b6082..3c6f829a05 100644 --- a/connect.c +++ b/

[PATCH v7 00/15] Trace2 tracing facility

2019-02-22 Thread Jeff Hostetler via GitGitGadget
V7 addresses: [] squashes in the fixup for windows process ancestry calculation. [] adds optional socket_type parameter to the unix domain socket syntax. [] allow unix domain socket syntax to try both stream and dgram if socket_type not specified. [] add Perl prereq checks for JSON:PP in trace2 tes

[PATCH v7 02/15] trace2: create new combined trace facility

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create a new unified tracing facility for git. The eventual intent is to replace the current trace_printf* and trace_performance* routines with a unified set of git_trace2* routines. In addition to the usual printf-style API, trace2 provides higer-level event verbs with fix

[PATCH v7 09/15] trace2:data: add trace2 instrumentation to index read/write

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add trace2 events to measure reading and writing the index. Signed-off-by: Jeff Hostetler --- read-cache.c | 51 ++- 1 file changed, 50 insertions(+), 1 deletion(-) diff --git a/read-cache.c b/read-cache.c index bfff271a3d..

[PATCH v7 06/15] trace2:data: add trace2 sub-process classification

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add trace2 classification for long-running processes started in sub-process.c Signed-off-by: Jeff Hostetler --- sub-process.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sub-process.c b/sub-process.c index 8d2a1707cf..3f4af93555 100644 --- a/sub-process.c +++ b/sub

[PATCH v7 14/15] trace2: t/helper/test-trace2, t0210.sh, t0211.sh, t0212.sh

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create unit tests for Trace2. Signed-off-by: Jeff Hostetler --- Makefile | 1 + t/helper/test-tool.c | 1 + t/helper/test-tool.h | 1 + t/helper/test-trace2.c| 273 ++ t/t0210-trace2-normal.sh | 135

[PATCH v7 03/15] trace2: collect Windows-specific process information

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add platform-specific interface to log information about the current process. On Windows, this interface is used to indicate whether the git process is running under a debugger and list names of the process ancestors. Information for other platforms is left for a future eff

[PATCH v7 05/15] trace2:data: add editor/pager child classification

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add trace2 process classification for editor and pager child processes. Signed-off-by: Jeff Hostetler --- editor.c | 1 + pager.c | 1 + 2 files changed, 2 insertions(+) diff --git a/editor.c b/editor.c index c985eee1f9..71547674ab 100644 --- a/editor.c +++ b/editor.c @@

[PATCH v7 11/15] trace2:data: add subverb to checkout command

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- builtin/checkout.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/builtin/checkout.c b/builtin/checkout.c index 6fadf412e8..f911c88bb4 100644 --- a/builtin/checkout.c +++ b/builtin/checkout.c @@ -262,6 +262,8 @@ static int check

[PATCH v7 15/15] trace2: add for_each macros to clang-format

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- .clang-format | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.clang-format b/.clang-format index de1c8b5c77..41d4cd23fd 100644 --- a/.clang-format +++ b/.clang-format @@ -149,7 +149,7 @@ Cpp11BracedListStyle: false #

[PATCH v7 10/15] trace2:data: pack-objects: add trace2 regions

2019-02-22 Thread Derrick Stolee via GitGitGadget
From: Derrick Stolee When studying the performance of 'git push' we would like to know how much time is spent at various parts of the command. One area that could cause performance trouble is 'git pack-objects'. Add trace2 regions around the three main actions taken in this command: 1. Enumerat

[PATCH v7 13/15] trace2:data: add subverb for rebase

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- builtin/rebase.c | 17 + 1 file changed, 17 insertions(+) diff --git a/builtin/rebase.c b/builtin/rebase.c index 774264bae8..f5ac4fe2ea 100644 --- a/builtin/rebase.c +++ b/builtin/rebase.c @@ -850,6 +850,14 @@ int cmd_rebas

[PATCH v7 04/15] trace2:data: add trace2 regions to wt-status

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add trace2_region_enter() and trace2_region_leave() calls around the various phases of a status scan. This gives elapsed time for each phase in the GIT_TR2_PERF and GIT_TR2_EVENT trace target. Also, these Trace2 calls now use s->repo rather than the_repository. Signed-off-

[PATCH v7 01/15] trace2: Documentation/technical/api-trace2.txt

2019-02-22 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Created design document for Trace2 feature. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 1350 1 file changed, 1350 insertions(+) create mode 100644 Documentation/technical/api-trace2.txt diff --git a/Documentation/t

Re: [PATCH v5 05/10] add-interactive.c: implement status command

2019-02-22 Thread Junio C Hamano
"Slavica Djukic via GitGitGadget" writes: > +static int parse_color_slot(const char *slot) > +{ > + if (!strcasecmp(slot, "prompt")) > + return COLOR_PROMPT; > + if (!strcasecmp(slot, "header")) > + return COLOR_HEADER; > + if (!strcasecmp(slot, "help")) > +

Re: [PATCH v2 0/6] Makefile: allow for combining DEVELOPER= and CFLAGS="..."

2019-02-22 Thread Ævar Arnfjörð Bjarmason
On Fri, Feb 22 2019, Jeff King wrote: > On Fri, Feb 22, 2019 at 03:41:21PM +0100, Ævar Arnfjörð Bjarmason wrote: > >> This fixes a long-standing annoyance of mine of not being able to set >> my own CFLAGS combined with DEVELOPER="...". > > I already do this, via my config.mak. Are you passing th

Re: [PATCH v2 2/6] Makefile: move "strip" assignment down from flags

2019-02-22 Thread Ramsay Jones
On 22/02/2019 15:18, Jeff King wrote: > On Fri, Feb 22, 2019 at 03:41:23PM +0100, Ævar Arnfjörð Bjarmason wrote: > >> Move the assignment of the "STRIP" variable down to where we're >> setting variables with the names of other programs. >> >> For consistency with those use "=" for the assignmen

Re: [PATCH v5 04/10] add-interactive.c: implement list_and_choose

2019-02-22 Thread Junio C Hamano
"Slavica Djukic via GitGitGadget" writes: > +#define HEADER_INDENT " " > + > enum collection_phase { > WORKTREE, > INDEX > @@ -27,6 +29,61 @@ struct collection_status { > struct hashmap file_map; > }; > > +struct list_and_choose_options { > + int column_n; > + u

Re: [PATCH 2/8] tests: always test fetch of unreachable with v0

2019-02-22 Thread Junio C Hamano
Jeff King writes: > On Thu, Feb 14, 2019 at 11:58:25AM -0800, Jonathan Tan wrote: > >> > On Tue, Feb 05, 2019 at 04:21:16PM -0800, Jonathan Tan wrote: >> > >> > > Some tests check that fetching an unreachable object fails, but protocol >> > > v2 allows such fetches. Unset GIT_TEST_PROTOCOL_VERSI

Re: [PATCH 1/3] builtin/log: downcase the beginning of error messages

2019-02-22 Thread Junio C Hamano
Eric Sunshine writes: >> - die(_("Failed to get upstream, if you want to record >> base commit automatically,\n" >> + die(_("failed to get upstream, if you want to record >> base commit automatically,\n" >> "please use gi

Re: [PATCH 3/3] format-patch: --no-clobber refrains from overwriting output files

2019-02-22 Thread Eric Sunshine
On Fri, Feb 22, 2019 at 3:11 PM Junio C Hamano wrote: > If you keep an output for an older iteration of the same topic in > the same directory around and use "git format-patch" to prepare a > newer iteration of the topic, those commits that happen to be at the > same position in the series that ha

Re: [PATCH 1/3] builtin/log: downcase the beginning of error messages

2019-02-22 Thread Eric Sunshine
On Fri, Feb 22, 2019 at 3:11 PM Junio C Hamano wrote: > diff --git a/builtin/log.c b/builtin/log.c > @@ -911,7 +911,7 @@ static void get_patch_ids(struct rev_info *rev, struct > patch_ids *ids) > if (rev->pending.nr != 2) > - die(_("Need exactly one range.")); > +

[PATCH 3/3] format-patch: --no-clobber refrains from overwriting output files

2019-02-22 Thread Junio C Hamano
If you keep an output for an older iteration of the same topic in the same directory around and use "git format-patch" to prepare a newer iteration of the topic, those commits that happen to be at the same position in the series that have not been retitled will get the same filename---and the comma

[PATCH 2/3] format-patch: notice failure to open cover letter for writing

2019-02-22 Thread Junio C Hamano
The make_cover_letter() function is supposed to open a new file for writing, and let the caller write into it via FILE *rev->diffopt.file but because the function does not return anything, the caller does not bother checking the return value. Make sure it dies, instead of keep going with a NULL ou

[PATCH 0/3] format-patch --no-clobber

2019-02-22 Thread Junio C Hamano
If you keep an output for an older iteration of the same topic in the same directory around and use "git format-patch" to prepare a newer iteration of the topic, those commits that happen to be at the same position in the series that have not been retitled will get the same filename---and the comma

[PATCH 1/3] builtin/log: downcase the beginning of error messages

2019-02-22 Thread Junio C Hamano
Signed-off-by: Junio C Hamano --- builtin/log.c | 38 +++--- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/builtin/log.c b/builtin/log.c index 57869267d8..f2d1fbf18a 100644 --- a/builtin/log.c +++ b/builtin/log.c @@ -513,7 +513,7 @@ static int sho

Re: Ideas for even more compact fetch.output=compact output

2019-02-22 Thread Junio C Hamano
Junio C Hamano writes: > Duy Nguyen writes: > >>> If we had this: >>> >>> From github.com:git/git >>>a7da99ff1b..28d0017056 next-> origin/* >>> + e911e946c2...9cc6aca6e9 pu -> origin/* (forced >>> update) >>>a7da99ff1b..28d0017056 ref

Re: git format-patch can clobber existing patch

2019-02-22 Thread Junio C Hamano
"brian m. carlson" writes: > On Thu, Feb 21, 2019 at 03:40:09PM -0800, Junio C Hamano wrote: >> Σταύρος Ντέντος writes: >> > Would it make sense / be easy enough to have some clobbering check / flag? >> >> Given that use of '-o' to redirect to a fresh/new directory would >> reduce the risk of

[PATCH v3] commit-graph tests: fix unportable "dd" invocation

2019-02-22 Thread Junio C Hamano
Todd Zullinger writes: > s/ as/ has/ ? Oops and thanks. Here is my second attempt (which makes it v3). -- >8 -- From: Ævar Arnfjörð Bjarmason Date: Thu, 21 Feb 2019 20:28:49 +0100 Change an unportable invocation of "dd" with count=0, that wanted to truncate the commit-graph file. In POSIX i

Re: [PATCH v2 5/5] remote-curl: use post_rpc() for protocol v2 also

2019-02-22 Thread Eric Sunshine
On Fri, Feb 22, 2019 at 8:18 AM Eric Sunshine wrote: > On Thu, Feb 21, 2019 at 3:25 PM Jonathan Tan wrote: > > + for i in $(test_seq 1 1500) > > + do > > + # do not use here-doc, because it requires a process > > + # per loop iteration > > + e

Re: [PATCH 1/2] rebase tests: test linear branch topology

2019-02-22 Thread Junio C Hamano
Jeff King writes: >> While I'm at it add a --fork-point test, strictly speaking this is >> redundant to the existing '' test, as no argument to rebase implies >> --fork-point. But now it's easier to grep for tests that explicitly >> stress --fork-point. > > That makes sense. > >> +test_expect_suc

Re: [PATCH 2/2] commit-graph tests: fix cryptic unportable "dd" invocation

2019-02-22 Thread Todd Zullinger
Junio C Hamano wrote: > Ævar Arnfjörð Bjarmason writes: > >> It was my reading of the seek=* section ("the implementation shall seek >> to the specified offset"). I didn't spot that bit covered in of=*. Yeah, >> I see that's defined & safe after reading that. > > OK, so... > > -- >8 -- > From:

Re: [PATCH 2/2] commit-graph tests: fix cryptic unportable "dd" invocation

2019-02-22 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > It was my reading of the seek=* section ("the implementation shall seek > to the specified offset"). I didn't spot that bit covered in of=*. Yeah, > I see that's defined & safe after reading that. OK, so... -- >8 -- From: Ævar Arnfjörð Bjarmason Date: Thu, 21

Re: Ideas for even more compact fetch.output=compact output

2019-02-22 Thread Junio C Hamano
Duy Nguyen writes: >> If we had this: >> >> From github.com:git/git >>a7da99ff1b..28d0017056 next-> origin/* >> + e911e946c2...9cc6aca6e9 pu -> origin/* (forced >> update) >>a7da99ff1b..28d0017056 refs/[pull/412/head] -> origin/* >>

hello dear

2019-02-22 Thread Aysha Gadafi
Assalamu Alaikum Wa Rahmatullahi Wa Barakatuh, hello dear I came across your contact during my private search. Mrs Aisha Al- Qaddafi is my name, the only daughter of late Libyan president, am a single Mother and a Widow with three Children.I have funds the sum of $27.5 million USD for, investme

Re: [PATCH 1/1] Introduce "precious" file concept

2019-02-22 Thread Junio C Hamano
Duy Nguyen writes: > On Thu, Feb 21, 2019 at 5:39 AM Junio C Hamano wrote: >> > So now you would need to >> > add more or less the same set of ignore rules in .gitattributes to >> > mark them trashable, and gitignore/gitattributes rules are not exactly >> > compatible, you can't just blindly cop

Re: [PATCH] format-patch: notice failure to open cover letter for writing

2019-02-22 Thread Junio C Hamano
Jeff King writes: > I'd suggest s/F/f/ in the message to match our usual style, though I see > this code has a lot of capitalized errors already. :) Yup, I'd prepare a prelim clean-up before this step. >> +test_expect_success 'failure to write cover-letter aborts gracefully' ' >> +test_when

Re: [PATCH 3/3] bisect: make diff-tree output prettier

2019-02-22 Thread Junio C Hamano
Jeff King writes: > After completing a bisection, we print out the commit we found using an > internal version of diff-tree. The result is aesthetically lacking: > > - it shows a raw diff, which is generally less informative for human > readers than "--stat --summary" (which we already deci

Re: [PATCH 0/3] prettier bisect output

2019-02-22 Thread Junio C Hamano
Jeff King writes: > I've run across this many times, too. Since it's been bugging me for a > decade, I thought I'd finally try to address it. Here are some patches. > > There was some discussion about a year ago about just using "git show" > for this output: > > > https://public-inbox.org/git/

Re: [PATCH 2/2] rebase: don't rebase linear topology with --fork-point

2019-02-22 Thread Ævar Arnfjörð Bjarmason
On Fri, Feb 22 2019, Jeff King wrote: > On Thu, Feb 21, 2019 at 10:40:59PM +0100, Ævar Arnfjörð Bjarmason wrote: > >> Fix a regression introduced in 4f21454b55 ("merge-base: handle >> --fork-point without reflog", 2016-10-12). >> [...] > > OK, your explanation mostly makes sense to me, except fo

RE: Fetching master branch with tags associated with it

2019-02-22 Thread Randall S. Becker
On February 22, 2019 11:07, Jeff King wrote: > To: Dominik Salvet > Cc: git@vger.kernel.org > Subject: Re: Fetching master branch with tags associated with it > > On Thu, Feb 21, 2019 at 06:02:54PM +0100, Dominik Salvet wrote: > > > Now, I want to refresh the repository the same way - fetching o

Re: [PATCH RFC 0/20] cat-file: start using formatting logic from ref-filter

2019-02-22 Thread Olga Telezhnaya
пт, 22 февр. 2019 г. в 19:09, Eric Sunshine : > > On Fri, Feb 22, 2019 at 10:58 AM Olga Telezhnaya > wrote: > > I also have a question about site https://git-scm.com/docs/ > > I thought it is updated automatically based on Documentation folder in > > the project, but it is not true. I edited docs

[PATCH RFC 14/20] cat-file: move print_object_or_die to ref-filter

2019-02-22 Thread Olga Telezhnaya
Move printing function to ref-filter, it is logical because we move all formatting/printing logic to ref-filter. It could be much better if we embed this logic into current flows in ref-filter, but it looks like the task for another patch. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c |

Re: [PATCH RFC 0/20] cat-file: start using formatting logic from ref-filter

2019-02-22 Thread Eric Sunshine
On Fri, Feb 22, 2019 at 10:58 AM Olga Telezhnaya wrote: > I also have a question about site https://git-scm.com/docs/ > I thought it is updated automatically based on Documentation folder in > the project, but it is not true. I edited docs for for-each-ref in > December, I still see my patch in ma

Re: Fetching master branch with tags associated with it

2019-02-22 Thread Jeff King
On Thu, Feb 21, 2019 at 06:02:54PM +0100, Dominik Salvet wrote: > Now, I want to refresh the repository the same way - fetching only > commits from the master branch and tags that are pointing to the > master branch and also refresh those tags as well in case of their > target commit change at the

[PATCH RFC 13/20] cat-file: rewrite print_object_or_die

2019-02-22 Thread Olga Telezhnaya
In the next commit I will move function print_object_or_die to ref-filter, and I decided to rewrite it a little so that it becomes much more flatten and a little bit shorter. I also changed input parameters, it allows me to move it to ref-filter, ref-filter knows nothing about batch_options. The l

[PATCH RFC 08/20] cat-file: remove rest from expand_data

2019-02-22 Thread Olga Telezhnaya
Get rid of rest field in struct expand_data. expand_data may be global further as we use it in ref-filter also, so we need to remove cat-file specific fields from it. All globals that I add through this patch will be deleted in the end, so treat it just as the middle step. Signed-off-by: Olga Tel

[PATCH RFC 10/20] cat-file: inline stream_blob

2019-02-22 Thread Olga Telezhnaya
Inline function stream_blob, it simplifies further migrating process. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 26 -- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/builtin/cat-file.c b/builtin/cat-file.c index edf45f078b919..cd9a4447c8da9

[PATCH RFC 06/20] cat-file: remove mark_query from expand_data

2019-02-22 Thread Olga Telezhnaya
Get rid of mark_query field in struct expand_data. expand_data may be global further as we use it in ref-filter also, so we need to remove cat-file specific fields from it. All globals that I add through this patch will be deleted in the end, so treat it just as the middle step. Signed-off-by: Ol

[PATCH RFC 05/20] cat-file: remove split_on_whitespace

2019-02-22 Thread Olga Telezhnaya
Get rid of split_on_whitespace field in struct expand_data. expand_data may be global further as we use it in ref-filter also, so we need to remove cat-file specific fields from it. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 16 +++- 1 file changed, 3 insertions(+), 13 d

[PATCH RFC 17/20] cat-file: reuse ref-filter formatting logic

2019-02-22 Thread Olga Telezhnaya
Start using general ref-filter formatting logic in cat-file. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 111 - ref-filter.c | 39 +++- ref-filter.h | 4 +- 3 files changed, 49 insertions(+), 105 deletions(-) dif

[PATCH RFC 09/20] ref-filter: make expand_data global

2019-02-22 Thread Olga Telezhnaya
Put struct expand_data into global scope to reuse it in cat-file. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 15 --- ref-filter.c | 11 +-- ref-filter.h | 12 3 files changed, 13 insertions(+), 25 deletions(-) diff --git a/builtin/cat-fi

[PATCH RFC 02/20] ref-filter: rename field in ref_array_item stuct

2019-02-22 Thread Olga Telezhnaya
Rename objectname field to oid in struct ref_array_item. We usually use objectname word for string representation of object id, so oid explains the content better. Signed-off-by: Olga Telezhnaia --- builtin/ls-remote.c | 2 +- ref-filter.c| 8 ref-filter.h| 2 +- 3 files

[PATCH RFC 04/20] for-each-ref: tests for new atom %(rest) added

2019-02-22 Thread Olga Telezhnaya
Add tests for new formatting atom %(rest). We need this atom for cat-file command. Signed-off-by: Olga Telezhnaia --- t/t6300-for-each-ref.sh | 6 ++ 1 file changed, 6 insertions(+) diff --git a/t/t6300-for-each-ref.sh b/t/t6300-for-each-ref.sh index 0ffd63071392e..fb361369a037c 100755 ---

[PATCH RFC 12/20] cat-file: remove batch_write function

2019-02-22 Thread Olga Telezhnaya
Correct me if I am wrong, but it was not really good idea to implement batch_write in cmd_cat_file. Maybe it's a good task for newbies to add flag (whether we accept batch write or not) to write_or_die? Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 17 - 1 file changed,

[PATCH RFC 15/20] ref-filter: add raw formatting option

2019-02-22 Thread Olga Telezhnaya
Add new formatting option %(raw), it means that we want to print all the file without any changes. It will help further to migrate all cat-file formatting logic from cat-file to ref-filter. For now, we just treat it as the empty string. Signed-off-by: Olga Telezhnaia --- ref-filter.c | 13 ++

[PATCH RFC 07/20] cat-file: remove skip_object_info

2019-02-22 Thread Olga Telezhnaya
Get rid of skip_object_info field in struct expand_data. expand_data may be global further as we use it in ref-filter also, so we need to remove cat-file specific fields from it. All globals that I add through this patch will be deleted in the end, so treat it just as the middle step. Signed-off-

[PATCH RFC 16/20] for-each-ref: tests for new atom %(raw) added

2019-02-22 Thread Olga Telezhnaya
Add tests for new formatting atom %(raw). We need this atom for cat-file command. Signed-off-by: Olga Telezhnaia --- t/t6300-for-each-ref.sh | 6 ++ 1 file changed, 6 insertions(+) diff --git a/t/t6300-for-each-ref.sh b/t/t6300-for-each-ref.sh index fb361369a037c..6a5626d537f35 100755 --- a

[PATCH RFC 03/20] ref-filter: add rest formatting option

2019-02-22 Thread Olga Telezhnaya
Add rest option that allows to add string into ref_array_item and then put it into specific place of the output. We are using it now in cat-file command: user could put anything in the input after objectname, and it will appear in the output in place of %(rest). Signed-off-by: Olga Telezhnaia ---

[PATCH RFC 01/20] cat-file: reuse struct ref_format

2019-02-22 Thread Olga Telezhnaya
Start using ref_format struct instead of simple char*. Need that for further reusing of formatting logic from ref-filter. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/builtin/cat-file.c b/builtin/cat-f

[PATCH RFC 19/20] cat-file: tests for new atoms added

2019-02-22 Thread Olga Telezhnaya
Add some tests for new formatting atoms from ref-filter. Some of new atoms are supported automatically, some of them are expanded into empty string (because they are useless for some types of objects). Signed-off-by: Olga Telezhnaia --- t/t1006-cat-file.sh | 48 ++

[PATCH RFC 20/20] cat-file: update docs

2019-02-22 Thread Olga Telezhnaya
Update the docs for cat-file command. Some new formatting atoms added because of reusing ref-filter code. Actually, %(rest) is supported for all ref-filter commands, but it has the meaning only for cat-file, that's why I decided to leave it here. Signed-off-by: Olga Telezhnaia --- Documentation

[PATCH RFC 18/20] cat-file: get rid of expand_data

2019-02-22 Thread Olga Telezhnaya
Clean up cat-file after moving all formatting logic to ref-filter. We do not need to use struct expand_data anymore. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 43 +++ ref-filter.c | 11 ++- ref-filter.h | 12

[PATCH RFC 11/20] cat-file: move filter_object to diff.c

2019-02-22 Thread Olga Telezhnaya
Move function filter_object to diff.c, like it is done with function textconv_object. Signed-off-by: Olga Telezhnaia --- builtin/cat-file.c | 23 --- diff.c | 23 +++ diff.h | 4 3 files changed, 27 insertions(+), 23 deletions

[PATCH RFC 0/20] cat-file: start using formatting logic from ref-filter

2019-02-22 Thread Olga Telezhnaya
Hi everyone, It was a long way for me, I got older (by 1 year) and smarter (hopefully), and maybe I will finish my Outreachy Internship task for now. (I am doing it just for one year and a half, that's OK) If serious: In this patch we remove cat-file formatting logic and reuse ref-filter logic the

Re: [PATCH v2 4/6] Makefile: Move *_LIBS assignment into its own section

2019-02-22 Thread Eric Sunshine
On Fri, Feb 22, 2019 at 9:41 AM Ævar Arnfjörð Bjarmason wrote: > Now the only other non-program assignment in the previous list is > PTHREAD_CFLAGS, which'll be moved elsewhere in a follow-up chang. s/chang/change/ > Signed-off-by: Ævar Arnfjörð Bjarmason

.gitignore alleged bug

2019-02-22 Thread Celestino, Federico
Dear Support Team, I am facing a serious issue with .gitignore (see attachment). The problem is that the folder contents of 04 - Software/SW Code/STM32/Lib/Drivers/CMSIS/Device/ are ignored because of a suspected misinterpretation of .gitignore. Here are some results that you could find useful

Re: how does one interpret "git diff ^"

2019-02-22 Thread Junio C Hamano
"Robert P. J. Day" writes: > was perusing the git FAQ and ran across this: > > How do I obtain a list of files which have changed in a given commit? > > $ git diff --name-only ^! > > > after playing with "git rev-parse", i figured out that the above was > equivalent to (using kernel "v4.

Re: [PATCH v2 6/6] Makefile: allow for combining DEVELOPER=1 and CFLAGS="..."

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 03:41:27PM +0100, Ævar Arnfjörð Bjarmason wrote: > So let's introduce a "DEVELOPER_CFLAGS" variable in config.mak.dev and > add it to ALL_CFLAGS. Before this the ALL_CFLAGS variable > would (basically, there's some nuance we won't go into) be set to: Yeah, I definitely thi

Re: [Suggestion] Add Skip for t9020

2019-02-22 Thread Jeff King
On Thu, Feb 21, 2019 at 03:58:37PM -0500, Todd Zullinger wrote: > > While this is a bit of a hack, it might be useful for skipping t9020 in > > environments where the svn.remote package is not installed. I can make this > > into a patch if this style is reasonable - guessing probably not and that

Re: [PATCH v2 4/6] Makefile: Move *_LIBS assignment into its own section

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 03:41:25PM +0100, Ævar Arnfjörð Bjarmason wrote: > Now the only other non-program assignment in the previous list is > PTHREAD_CFLAGS, which'll be moved elsewhere in a follow-up chang. Hmm. I get why this organization might make sense. But it also might be convenient to se

Re: [PATCH v2 2/6] Makefile: move "strip" assignment down from flags

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 03:41:23PM +0100, Ævar Arnfjörð Bjarmason wrote: > Move the assignment of the "STRIP" variable down to where we're > setting variables with the names of other programs. > > For consistency with those use "=" for the assignment instead of > "?=". I can't imagine why this wo

Re: [PATCH v2 0/6] Makefile: allow for combining DEVELOPER= and CFLAGS="..."

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 03:41:21PM +0100, Ævar Arnfjörð Bjarmason wrote: > This fixes a long-standing annoyance of mine of not being able to set > my own CFLAGS combined with DEVELOPER="...". I already do this, via my config.mak. Are you passing these on the command-line (and thus your CFLAGS= pr

Re: [PATCH 2/2] rebase: don't rebase linear topology with --fork-point

2019-02-22 Thread Jeff King
On Thu, Feb 21, 2019 at 10:40:59PM +0100, Ævar Arnfjörð Bjarmason wrote: > Fix a regression introduced in 4f21454b55 ("merge-base: handle > --fork-point without reflog", 2016-10-12). > [...] OK, your explanation mostly makes sense to me, except for one thing. > Then in 4f21454b55 ("merge-base: h

Re: [PATCH] Makefile: remove an out-of-date comment

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 11:56:58AM +0100, Ævar Arnfjörð Bjarmason wrote: > Remove a comment referring to a caveat that hasn't been applicable > since 18b0fc1ce1 ("Git.pm: Kill Git.xs for now", 2006-09-23). > > At the time of 8d7f586f13 ("Git.pm: Support for perl/ being built by a > different comp

Re: [PATCH 1/2] rebase tests: test linear branch topology

2019-02-22 Thread Jeff King
On Thu, Feb 21, 2019 at 10:40:58PM +0100, Ævar Arnfjörð Bjarmason wrote: > Add tests rebasing a linear branch topology to linear rebase tests > added in 2aad7cace2 ("add simple tests of consistency across rebase > types", 2013-06-06). I had trouble parsing this. Did you mean s/topology to/topolog

[PATCH v2 3/6] Makefile: add/remove comments at top and tweak whitespace

2019-02-22 Thread Ævar Arnfjörð Bjarmason
The top of the Makfile is mostly separated into logical steps like set default configuration, set programs etc., but there's some deviation from that. Let's add mostly comments where they're missing, remove those that don't add anything. The whitespace tweaking makes subsequent patches smaller. S

[PATCH v2 6/6] Makefile: allow for combining DEVELOPER=1 and CFLAGS="..."

2019-02-22 Thread Ævar Arnfjörð Bjarmason
Ever since the DEVELOPER=1 facility introduced there's been no way to have custom CFLAGS (e.g. CFLAGS="-O0 -g -ggdb3") while still benefiting from the set of warnings and assertions DEVELOPER=1 enables. This is because the semantics of variables in the Makefile are such that the user setting CFLAG

[PATCH v2 5/6] Makefile: move the setting of *FLAGS closer to "include"

2019-02-22 Thread Ævar Arnfjörð Bjarmason
Move the setting of variables like CFLAGS down past settings like "prefix" and default programs like "TAR" to just before we do the include from "config.mak.*". There's no functional changes here yet, but move note that "ALL_CFLAGS" and "ALL_LDFLAGS" are moved below the include. A follow-up change

[PATCH v2 2/6] Makefile: move "strip" assignment down from flags

2019-02-22 Thread Ævar Arnfjörð Bjarmason
Move the assignment of the "STRIP" variable down to where we're setting variables with the names of other programs. For consistency with those use "=" for the assignment instead of "?=". I can't imagine why this would need to be different than the rest, and 4dc00021f7 ("Makefile: add 'strip' targe

[PATCH v2 4/6] Makefile: Move *_LIBS assignment into its own section

2019-02-22 Thread Ævar Arnfjörð Bjarmason
Now the only other non-program assignment in the previous list is PTHREAD_CFLAGS, which'll be moved elsewhere in a follow-up chang. Signed-off-by: Ævar Arnfjörð Bjarmason --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 0870fd4651..596

[PATCH v2 0/6] Makefile: allow for combining DEVELOPER= and CFLAGS="..."

2019-02-22 Thread Ævar Arnfjörð Bjarmason
This fixes a long-standing annoyance of mine of not being able to set my own CFLAGS combined with DEVELOPER="...". There *should* be no other functional changes, but I'm moving around some core Makefile logic, so this needs to be carefully reviewed. I've tried installing with this, setting flags

[PATCH v2 1/6] Makefile: remove an out-of-date comment

2019-02-22 Thread Ævar Arnfjörð Bjarmason
Remove a comment referring to a caveat that hasn't been applicable since 18b0fc1ce1 ("Git.pm: Kill Git.xs for now", 2006-09-23). At the time of 8d7f586f13 ("Git.pm: Support for perl/ being built by a different compiler", 2006-06-25) some of the code in perl would be built by a C compiler, but supp

Re: [PATCH 2/2] commit-graph tests: fix cryptic unportable "dd" invocation

2019-02-22 Thread Ævar Arnfjörð Bjarmason
On Fri, Feb 22 2019, SZEDER Gábor wrote: > On Thu, Feb 21, 2019 at 11:26:26PM +0100, Ævar Arnfjörð Bjarmason wrote: >> >> - dd of="$objdir/info/commit-graph" bs=1 seek="$zero_pos" count=0 && >> >> + perl -we 'truncate $ARGV[0], $ARGV[1] if -s $ARGV[0] > $ARGV[1]' \ >> >> + $objdir/info/c

Re: bug - git version 2.20.1.windows.1

2019-02-22 Thread Jeff King
On Fri, Feb 22, 2019 at 02:26:51PM +0100, Krzysztof Sobierajczyk wrote: > ksobierajczyk@KME43 MINGW64 /d/Simple repository (master) > $ git status > On branch master > Changes to be committed: > (use "git reset HEAD ..." to unstage) > > renamed:to remove.txt -> new name.txt >

Re: how does one interpret "git diff ^"

2019-02-22 Thread Ævar Arnfjörð Bjarmason
On Fri, Feb 22 2019, Robert P. J. Day wrote: > was perusing the git FAQ and ran across this: > > How do I obtain a list of files which have changed in a given commit? > > $ git diff --name-only ^! > > > after playing with "git rev-parse", i figured out that the above was > equivalent to

bug - git version 2.20.1.windows.1

2019-02-22 Thread Krzysztof Sobierajczyk
for example, I've created a simple repository. Containing two files ('to rename.txt' and 'to remove.txt'). I wanted to prepare for the index changing the name of the first file and deleting the second file. what git shows you looks wrong. Please check the four instructions $ git add . $ git commit

how does one interpret "git diff ^"

2019-02-22 Thread Robert P. J. Day
was perusing the git FAQ and ran across this: How do I obtain a list of files which have changed in a given commit? $ git diff --name-only ^! after playing with "git rev-parse", i figured out that the above was equivalent to (using kernel "v4.19" tag as an example): $ git diff v4.19

Re: [PATCH v2 5/5] remote-curl: use post_rpc() for protocol v2 also

2019-02-22 Thread Eric Sunshine
On Thu, Feb 21, 2019 at 3:25 PM Jonathan Tan wrote: > diff --git a/t/t5702-protocol-v2.sh b/t/t5702-protocol-v2.sh > @@ -542,7 +542,38 @@ test_expect_success 'clone with http:// using protocol > v2' ' > +test_expect_success 'clone big repository with http:// using protocol v2' ' > + test_wh

Re: [PATCH v5 03/10] add-interactive.c: implement list_modified

2019-02-22 Thread Slavica Djukic
On 21-Feb-19 9:27 PM, Junio C Hamano wrote: Junio C Hamano writes: A few things I missed in the previous message. + for (i = 0; i < stat.nr; i++) { + struct file_stat *entry; + const char *name = stat.files[i]->name; + unsigned int hash = strh

  1   2   >