git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH v2 2/3] reset: remove 'reset.quiet' config option

From
Victoria Dye via GitGitGadget <gitgitgadget@gmail.com>
Date
Mar 23, 2022, 18:17 UTC
Message-ID
<a25aff3ac7c5835445b4387c3d4cce82c6c36758.1648059480.git.gitgitgadget@gmail.com>
In-Reply-To
<pull.1184.v2.git.1648059480.gitgitgadget@gmail.com>
From: Victoria Dye <vdye@github.com>

Remove the 'reset.quiet' config option, remove '--no-quiet' documentation in 'Documentation/git-reset.txt'. In 4c3abd0551 (reset: add new reset.quiet config setting, 2018-10-23), 'reset.quiet' was introduced as a way to globally change the default behavior of 'git reset --mixed' to skip index refresh.

However, now that '--quiet' does not affect index refresh, 'reset.quiet' would only serve to globally silence logging. This was not the original intention of the config setting, and there's no precedent for such a setting in other commands with a '--quiet' option, so it appears to be obsolete.

In addition to the options & its documentation, remove 'reset.quiet' from the recommended config for 'scalar'.

Signed-off-by: Victoria Dye <vdye@github.com>
---
 Documentation/config.txt       | 2 --
 Documentation/config/reset.txt | 2 --
 Documentation/git-reset.txt    | 5 +----
 builtin/reset.c                | 1 -
 contrib/scalar/scalar.c        | 1 -
 t/t7102-reset.sh               | 3 +--
 6 files changed, 2 insertions(+), 12 deletions(-)
 delete mode 100644 Documentation/config/reset.txt
diff --git a/Documentation/config.txt b/Documentation/config.txt
index f0fb25a371c..43f5e6fd6d3 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -495,8 +495,6 @@ include::config/repack.txt[]
 
 include::config/rerere.txt[]
 
-include::config/reset.txt[]
-
 include::config/sendemail.txt[]
 
 include::config/sequencer.txt[]
diff --git a/Documentation/config/reset.txt b/Documentation/config/reset.txt
deleted file mode 100644
index 63b7c45aac2..00000000000
--- a/Documentation/config/reset.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-reset.quiet::
-	When set to true, 'git reset' will default to the '--quiet' option.
diff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt
index bc1646c3016..f4aca9dd35c 100644
--- a/Documentation/git-reset.txt
+++ b/Documentation/git-reset.txt
@@ -105,10 +105,7 @@ OPTIONS
 
 -q::
 --quiet::
---no-quiet::
-	Be quiet, only report errors. The default behavior is set by the
-	`reset.quiet` config option. `--quiet` and `--no-quiet` will
-	override the default behavior.
+	Be quiet, only report errors.
 
 --refresh::
 --no-refresh::
diff --git a/builtin/reset.c b/builtin/reset.c
index 1804d0eeb84..9ce55afd1be 100644
--- a/builtin/reset.c
+++ b/builtin/reset.c
@@ -423,7 +423,6 @@ int cmd_reset(int argc, const char **argv, const char *prefix)
 	};
 
 	git_config(git_reset_config, NULL);
-	git_config_get_bool("reset.quiet", &quiet);
 	git_config_get_bool("reset.refresh", &refresh);
 
 	argc = parse_options(argc, argv, prefix, options, git_reset_usage,
diff --git a/contrib/scalar/scalar.c b/contrib/scalar/scalar.c
index 7db2a97416e..58ca0e56f14 100644
--- a/contrib/scalar/scalar.c
+++ b/contrib/scalar/scalar.c
@@ -152,7 +152,6 @@ static int set_recommended_config(int reconfigure)
 		{ "pack.useBitmaps", "false", 1 },
 		{ "pack.useSparse", "true", 1 },
 		{ "receive.autoGC", "false", 1 },
-		{ "reset.quiet", "true", 1 },
 		{ "feature.manyFiles", "false", 1 },
 		{ "feature.experimental", "false", 1 },
 		{ "fetch.unpackLimit", "1", 1 },
diff --git a/t/t7102-reset.sh b/t/t7102-reset.sh
index 8b62bb39b3d..9e4c4deee35 100755
--- a/t/t7102-reset.sh
+++ b/t/t7102-reset.sh
@@ -488,8 +488,7 @@ test_expect_success '--mixed refreshes the index' '
 	# Verify default behavior (without --[no-]refresh or reset.refresh)
 	test_reset_refreshes_index &&
 
-	# With --quiet & reset.quiet
-	test_reset_refreshes_index "-c reset.quiet=true" &&
+	# With --quiet
 	test_reset_refreshes_index "" --quiet
 '
 
-- 
gitgitgadget
Previous: Victoria Dye via GitGitGadgetNext: Victoria Dye via GitGitGadget
Message 15 of 25 in “reset: make --no-refresh the only way to skip index refresh”
  1. 0/4 reset: make --no-refresh the only way to skip index refreshVictoria Dye via GitGitGadget, Mar 21, 2022
  2. 2/4 reset: deprecate 'reset.quiet' config optionVictoria Dye via GitGitGadget, Mar 21, 2022
  3. Phillip WoodMar 23, 2022
  4. 1/4 reset: do not make '--quiet' disable index refreshVictoria Dye via GitGitGadget, Mar 21, 2022
  5. Phillip WoodMar 23, 2022
  6. Victoria DyeMar 23, 2022
  7. 3/4 reset: deprecate 'reset.refresh' config optionVictoria Dye via GitGitGadget, Mar 21, 2022
  8. Phillip WoodMar 23, 2022
  9. Victoria DyeMar 23, 2022
  10. 4/4 reset: deprecate '--refresh', leaving only '--no-refresh'Victoria Dye via GitGitGadget, Mar 21, 2022
  11. Phillip WoodMar 23, 2022
  12. Victoria DyeMar 23, 2022
  13. 0/3 reset: make --no-refresh the only way to skip index refreshVictoria Dye via GitGitGadget, Mar 23, 2022
  14. 1/3 reset: do not make '--quiet' disable index refreshVictoria Dye via GitGitGadget, Mar 23, 2022
  15. 2/3 reset: remove 'reset.quiet' config optionVictoria Dye via GitGitGadget, Mar 23, 2022
  16. 3/3 reset: remove 'reset.refresh' config optionVictoria Dye via GitGitGadget, Mar 23, 2022
  17. Derrick StoleeMar 23, 2022
  18. Junio C HamanoMar 23, 2022
  19. Phillip WoodMar 24, 2022
  20. Junio C HamanoMar 24, 2022
  21. Junio C HamanoMar 24, 2022
  22. Victoria DyeMar 24, 2022
  23. Junio C HamanoMar 24, 2022
  24. Derrick StoleeMar 25, 2022
  25. Junio C HamanoMar 25, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.