Git development
 help / color / mirror / Atom feed
* [PATCH] git-gui: silence install recipes under "make -s"
@ 2026-06-03  9:04 Harald Nordgren via GitGitGadget
  2026-06-03 12:58 ` Johannes Sixt
  2026-06-03 18:13 ` [PATCH v2] " Harald Nordgren via GitGitGadget
  0 siblings, 2 replies; 4+ messages in thread
From: Harald Nordgren via GitGitGadget @ 2026-06-03  9:04 UTC (permalink / raw)
  To: git; +Cc: Harald Nordgren, Harald Nordgren

From: Harald Nordgren <haraldnordgren@gmail.com>

The split install/uninstall recipes embed "echo" calls that fire
even under "make -s", so install still prints "DEST /path" and
"INSTALL 644 about.tcl" banners. The existing "-s" block only
clears QUIET_GEN.

Wrap the whole "ifndef V" block in the canonical "-s" guard from
shared.mak, and drop the now-redundant narrow block.

Signed-off-by: Harald Nordgren <harald.nordgren@kostdoktorn.se>
---
    git-gui: silence install recipes under "make -s"

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-2318%2FHaraldNordgren%2Fgit-gui-respect-silent-flag-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-2318/HaraldNordgren/git-gui-respect-silent-flag-v1
Pull-Request: https://github.com/git/git/pull/2318

 git-gui/Makefile | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/git-gui/Makefile b/git-gui/Makefile
index ca01068810..d33204e875 100644
--- a/git-gui/Makefile
+++ b/git-gui/Makefile
@@ -64,6 +64,7 @@ REMOVE_F0  = $(RM_RF) # space is required here
 REMOVE_F1  =
 CLEAN_DST  = true
 
+ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s)
 ifndef V
 	QUIET          = @
 	QUIET_GEN      = $(QUIET)echo '   ' GEN '$@' &&
@@ -89,6 +90,7 @@ ifndef V
 	REMOVE_F0 = dst=
 	REMOVE_F1 = && echo '   ' REMOVE `basename "$$dst"` && $(RM_RF) "$$dst"
 endif
+endif
 
 TCLTK_PATH ?= wish
 ifeq (./,$(dir $(TCLTK_PATH)))
@@ -97,10 +99,6 @@ else
 	TCL_PATH ?= $(dir $(TCLTK_PATH))$(notdir $(subst wish,tclsh,$(TCLTK_PATH)))
 endif
 
-ifeq ($(findstring $(firstword -$(MAKEFLAGS)),s),s)
-QUIET_GEN =
-endif
-
 -include config.mak
 
 DESTDIR_SQ = $(subst ','\'',$(DESTDIR))

base-commit: 1666c1265231b0bc5f613fbbf3f0a9896cdef76e
-- 
gitgitgadget

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] git-gui: silence install recipes under "make -s"
  2026-06-03  9:04 [PATCH] git-gui: silence install recipes under "make -s" Harald Nordgren via GitGitGadget
@ 2026-06-03 12:58 ` Johannes Sixt
  2026-06-03 18:03   ` Harald Nordgren
  2026-06-03 18:13 ` [PATCH v2] " Harald Nordgren via GitGitGadget
  1 sibling, 1 reply; 4+ messages in thread
From: Johannes Sixt @ 2026-06-03 12:58 UTC (permalink / raw)
  To: Harald Nordgren; +Cc: git, Harald Nordgren via GitGitGadget

Am 03.06.26 um 11:04 schrieb Harald Nordgren via GitGitGadget:
> From: Harald Nordgren <haraldnordgren@gmail.com>
> 
> The split install/uninstall recipes embed "echo" calls that fire
> even under "make -s", so install still prints "DEST /path" and
> "INSTALL 644 about.tcl" banners. The existing "-s" block only
> clears QUIET_GEN.

Good catch.

> Wrap the whole "ifndef V" block in the canonical "-s" guard from
> shared.mak, and drop the now-redundant narrow block.

Can we please mention shared.mak in a way that doesn't assume that this
patch was made in the Git repository?

> +ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s)
>  ifndef V
>  	QUIET          = @
>  	QUIET_GEN      = $(QUIET)echo '   ' GEN '$@' &&
> @@ -89,6 +90,7 @@ ifndef V
>  	REMOVE_F0 = dst=
>  	REMOVE_F1 = && echo '   ' REMOVE `basename "$$dst"` && $(RM_RF) "$$dst"
>  endif
> +endif

> -ifeq ($(findstring $(firstword -$(MAKEFLAGS)),s),s)

I would have expected that the old and the new condition expressions
only differ in the ifeq vs. ifneq, but they are different in more than
that. Assuming that the new expression is correct, was the old one
incorrect?

> -QUIET_GEN =
> -endif
-- Hannes


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] git-gui: silence install recipes under "make -s"
  2026-06-03 12:58 ` Johannes Sixt
@ 2026-06-03 18:03   ` Harald Nordgren
  0 siblings, 0 replies; 4+ messages in thread
From: Harald Nordgren @ 2026-06-03 18:03 UTC (permalink / raw)
  To: Johannes Sixt; +Cc: git, Harald Nordgren via GitGitGadget

> Can we please mention shared.mak in a way that doesn't assume that this
> patch was made in the Git repository?

Good point!

> > +ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s)
> >  ifndef V
> >       QUIET          = @
> >       QUIET_GEN      = $(QUIET)echo '   ' GEN '$@' &&
> > @@ -89,6 +90,7 @@ ifndef V
> >       REMOVE_F0 = dst=
> >       REMOVE_F1 = && echo '   ' REMOVE `basename "$$dst"` && $(RM_RF) "$$dst"
> >  endif
> > +endif
>
> > -ifeq ($(findstring $(firstword -$(MAKEFLAGS)),s),s)
>
> I would have expected that the old and the new condition expressions
> only differ in the ifeq vs. ifneq, but they are different in more than
> that. Assuming that the new expression is correct, was the old one
> incorrect?

Yeah, the old format doesn't seem to work when I use that with ifneq.
So I took this other format that is also used twice in shared.mak
(lines 40 and 46).


Harald

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v2] git-gui: silence install recipes under "make -s"
  2026-06-03  9:04 [PATCH] git-gui: silence install recipes under "make -s" Harald Nordgren via GitGitGadget
  2026-06-03 12:58 ` Johannes Sixt
@ 2026-06-03 18:13 ` Harald Nordgren via GitGitGadget
  1 sibling, 0 replies; 4+ messages in thread
From: Harald Nordgren via GitGitGadget @ 2026-06-03 18:13 UTC (permalink / raw)
  To: git; +Cc: Johannes Sixt, Harald Nordgren, Harald Nordgren

From: Harald Nordgren <haraldnordgren@gmail.com>

Several install and uninstall recipes embed "echo" calls that fire as
part of the recipe itself, so the install banners (DEST, INSTALL,
LINK, REMOVE) were visible whenever the variables expand non-empty.

Guard the whole "ifndef V" block on "-s" so the loud variants are
selected only when "-s" is absent and V=1 is unset.

Signed-off-by: Harald Nordgren <harald.nordgren@kostdoktorn.se>
---
    git-gui: silence install recipes under "make -s"
    
     * Clarified commit message.

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-2318%2FHaraldNordgren%2Fgit-gui-respect-silent-flag-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-2318/HaraldNordgren/git-gui-respect-silent-flag-v2
Pull-Request: https://github.com/git/git/pull/2318

Range-diff vs v1:

 1:  b9f2b16a8d ! 1:  4e4029c8e8 git-gui: silence install recipes under "make -s"
     @@ Metadata
       ## Commit message ##
          git-gui: silence install recipes under "make -s"
      
     -    The split install/uninstall recipes embed "echo" calls that fire
     -    even under "make -s", so install still prints "DEST /path" and
     -    "INSTALL 644 about.tcl" banners. The existing "-s" block only
     -    clears QUIET_GEN.
     +    Several install and uninstall recipes embed "echo" calls that fire as
     +    part of the recipe itself, so the install banners (DEST, INSTALL,
     +    LINK, REMOVE) were visible whenever the variables expand non-empty.
      
     -    Wrap the whole "ifndef V" block in the canonical "-s" guard from
     -    shared.mak, and drop the now-redundant narrow block.
     +    Guard the whole "ifndef V" block on "-s" so the loud variants are
     +    selected only when "-s" is absent and V=1 is unset.
      
          Signed-off-by: Harald Nordgren <harald.nordgren@kostdoktorn.se>
      


 git-gui/Makefile | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/git-gui/Makefile b/git-gui/Makefile
index ca01068810..d33204e875 100644
--- a/git-gui/Makefile
+++ b/git-gui/Makefile
@@ -64,6 +64,7 @@ REMOVE_F0  = $(RM_RF) # space is required here
 REMOVE_F1  =
 CLEAN_DST  = true
 
+ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s)
 ifndef V
 	QUIET          = @
 	QUIET_GEN      = $(QUIET)echo '   ' GEN '$@' &&
@@ -89,6 +90,7 @@ ifndef V
 	REMOVE_F0 = dst=
 	REMOVE_F1 = && echo '   ' REMOVE `basename "$$dst"` && $(RM_RF) "$$dst"
 endif
+endif
 
 TCLTK_PATH ?= wish
 ifeq (./,$(dir $(TCLTK_PATH)))
@@ -97,10 +99,6 @@ else
 	TCL_PATH ?= $(dir $(TCLTK_PATH))$(notdir $(subst wish,tclsh,$(TCLTK_PATH)))
 endif
 
-ifeq ($(findstring $(firstword -$(MAKEFLAGS)),s),s)
-QUIET_GEN =
-endif
-
 -include config.mak
 
 DESTDIR_SQ = $(subst ','\'',$(DESTDIR))

base-commit: 9ac3f193c05c2237e2b14ebaa1149e9fc8a1abe0
-- 
gitgitgadget

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-06-03 18:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-03  9:04 [PATCH] git-gui: silence install recipes under "make -s" Harald Nordgren via GitGitGadget
2026-06-03 12:58 ` Johannes Sixt
2026-06-03 18:03   ` Harald Nordgren
2026-06-03 18:13 ` [PATCH v2] " Harald Nordgren via GitGitGadget

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox