Subject: [PATCH 2/4] git-gui: remove hint_gc dialog

From: "Wolfgang Faust" <[email-masked]>
Date: Thu, 05 Mar 2026 21:30:47 -0800

Now that git-gui runs auto maintenance on commit, large piles of loose objects
are no longer a concern so we don't need to bother the user about them.

Signed-off-by: Wolfgang Faust <[email-masked]>
---
 Documentation/config/gui.adoc |  5 -----
 git-gui/git-gui.sh            |  3 ---
 git-gui/lib/database.tcl      | 26 --------------------------
 git-gui/po/bg.po              | 16 ----------------
 git-gui/po/de.po              | 17 -----------------
 git-gui/po/el.po              | 17 -----------------
 git-gui/po/fr.po              | 18 ------------------
 git-gui/po/hu.po              | 17 -----------------
 git-gui/po/it.po              | 16 ----------------
 git-gui/po/ja.po              | 16 ----------------
 git-gui/po/nb.po              | 17 -----------------
 git-gui/po/pt_br.po           | 17 -----------------
 git-gui/po/pt_pt.po           | 17 -----------------
 git-gui/po/ru.po              | 10 ----------
 git-gui/po/sv.po              | 17 -----------------
 git-gui/po/vi.po              | 17 -----------------
 git-gui/po/zh_cn.po           | 16 ----------------
 17 files changed, 262 deletions(-)

diff --git a/Documentation/config/gui.adoc b/Documentation/config/gui.adoc
index 1565c0af19..171be774d2 100644
--- a/Documentation/config/gui.adoc
+++ b/Documentation/config/gui.adoc
@@ -55,8 +55,3 @@ gui.blamehistoryctx::
 	linkgit:gitk[1] for the selected commit, when the `Show History
 	Context` menu item is invoked from 'git gui blame'. If this
 	variable is set to zero, the whole history is shown.
-
-gui.GCWarning::
-	Determines whether linkgit:git-gui[1] should prompt for garbage
-	collection when git detects a large number of loose objects in
-	the repository. The default value is "true".
diff --git a/git-gui/git-gui.sh b/git-gui/git-gui.sh
index d3d3aa14a9..29b708f9c8 100755
--- a/git-gui/git-gui.sh
+++ b/git-gui/git-gui.sh
@@ -3940,9 +3940,6 @@ after 1 {
 		$ui_comm configure -state disabled -background gray
 	}
 }
-if {[is_enabled multicommit] && ![is_config_false gui.gcwarning]} {
-	after 1000 hint_gc
-}
 if {[is_enabled retcode]} {
 	bind . <Destroy> {+terminate_me %W}
 }
diff --git a/git-gui/lib/database.tcl b/git-gui/lib/database.tcl
index 78732d8651..9b4cc98df5 100644
--- a/git-gui/lib/database.tcl
+++ b/git-gui/lib/database.tcl
@@ -86,29 +86,3 @@ proc do_fsck_objects {} {
 	lappend cmd --strict
 	console::exec $w $cmd
 }
-
-proc hint_gc {} {
-	set ndirs 1
-	set limit 8
-	if {[is_Windows]} {
-		set ndirs 4
-		set limit 1
-	}
-
-	set count [llength [glob \
-		-nocomplain \
-		-- \
-		[gitdir objects 4\[0-[expr {$ndirs-1}]\]/*]]]
-
-	if {$count >= $limit * $ndirs} {
-		set objects_current [expr {$count * 256/$ndirs}]
-		if {[ask_popup \
-			[mc "This repository currently has approximately %i loose objects.
-
-To maintain optimal performance it is strongly recommended that you compress the database.
-
-Compress the database now?" $objects_current]] eq yes} {
-			do_gc
-		}
-	}
-}
diff --git a/git-gui/po/bg.po b/git-gui/po/bg.po
index ff5adb25cc..2670bbb4ef 100644
--- a/git-gui/po/bg.po
+++ b/git-gui/po/bg.po
@@ -1167,22 +1167,6 @@ msgstr "Компресиране на базата с данни за обект
 msgid "Verifying the object database with fsck-objects"
 msgstr "Проверка на базата с данни за обектите с програмата „fsck-objects“"
 
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"В това хранилище в момента има към %i непакетирани обекти.\n"
-"\n"
-"За добра производителност се препоръчва да компресирате базата с данни за "
-"обектите.\n"
-"\n"
-"Да се започне ли компресирането?"
-
 #, tcl-format
 msgid "Invalid date from Git: %s"
 msgstr "Неправилни данни от Git: %s"
diff --git a/git-gui/po/de.po b/git-gui/po/de.po
index a8d5f61ca3..490ed25e0d 100644
--- a/git-gui/po/de.po
+++ b/git-gui/po/de.po
@@ -2682,23 +2682,6 @@ msgstr "Objektdatenbank komprimieren"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Die Objektdatenbank durch »fsck-objects« überprüfen lassen"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Dieses Repository enthält ungefähr %i nicht verknüpfte Objekte.\n"
-"\n"
-"Für eine optimale Performance wird empfohlen, die Datenbank des Repository "
-"zu komprimieren.\n"
-"\n"
-"Soll die Datenbank jetzt komprimiert werden?"
-
 #: lib/error.tcl:20
 #, tcl-format
 msgid "%s: error"
diff --git a/git-gui/po/el.po b/git-gui/po/el.po
index 3634ba469d..1c77b98b14 100644
--- a/git-gui/po/el.po
+++ b/git-gui/po/el.po
@@ -1410,23 +1410,6 @@ msgid "Verifying the object database with fsck-objects"
 msgstr ""
 "Γίνεται επαλήθευση της βάσης δεδομένων αντικειμένων με αντικείμενα fsck"
 
-#: lib/database.tcl:108
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database when more than %i loose objects exist.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Αυτό το αποθετήριο έχει αυτή τη στιγμή περίπου %i ελεύθερα αντικείμενα.\n"
-"\n"
-"Για τη διατήρηση βέλτιστων επιδόσεων συνιστάται να συμπιέσετε τη βάση "
-"δεδομένων όταν υπάρχουν περισσότερα από %i ελεύθερα αντικείμενα.\n"
-"\n"
-"Συμπίεση της βάσης δεδομένων τώρα;"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/fr.po b/git-gui/po/fr.po
index 878df65399..9da3e09ba2 100644
--- a/git-gui/po/fr.po
+++ b/git-gui/po/fr.po
@@ -1556,24 +1556,6 @@ msgstr "Compression de la base des objets"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Vérification de la base des objets avec fsck-objects"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Ce dépôt comprend actuellement environ %i objets ayant leur fichier "
-"particulier.\n"
-"\n"
-"Pour conserver une performance optimale, il est fortement recommandé de "
-"comprimer la base de donnée.\n"
-"\n"
-"Comprimer la base maintenant ?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/hu.po b/git-gui/po/hu.po
index d106dadac8..4404af74d6 100644
--- a/git-gui/po/hu.po
+++ b/git-gui/po/hu.po
@@ -1505,23 +1505,6 @@ msgstr "Az objektum adatbázis tömörítése"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Az objektum adatbázis ellenőrzése az fsck-objects használatával"
 
-#: lib/database.tcl:108
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database when more than %i loose objects exist.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Ennek a repónak jelenleg %i különálló objektuma van.\n"
-"\n"
-"Az optimális teljesítményhez erősen ajánlott az adatbázis tömörítése, ha "
-"több mint %i objektum létezik.\n"
-"\n"
-"Lehet most tömöríteni az adatbázist?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/it.po b/git-gui/po/it.po
index 1bd8b8e04f..b590dfbbd0 100644
--- a/git-gui/po/it.po
+++ b/git-gui/po/it.po
@@ -1552,22 +1552,6 @@ msgstr "Compressione dell'archivio in corso"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Verifica dell'archivio con fsck-objects in corso"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Questo archivio attualmente ha circa %i oggetti slegati.\n"
-"\n"
-"Per mantenere buone prestazioni si raccomanda di comprimere l'archivio.\n"
-"\n"
-"Comprimere l'archivio ora?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/ja.po b/git-gui/po/ja.po
index 2f61153ab9..d52bcd7f8c 100644
--- a/git-gui/po/ja.po
+++ b/git-gui/po/ja.po
@@ -1939,22 +1939,6 @@ msgstr "データベース圧縮"
 msgid "Verifying the object database with fsck-objects"
 msgstr "fsck-objects でオブジェクト・データベースを検証しています"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"このリポジトリにはおおよそ %i 個の個別オブジェクトがあります\n"
-"\n"
-"最適な性能を保つために、データベースを圧縮することを推奨します\n"
-"\n"
-"データベースを圧縮しますか？"
-
 #: lib/transport.tcl:6 lib/remote_add.tcl:132
 #, tcl-format
 msgid "fetch %s"
diff --git a/git-gui/po/nb.po b/git-gui/po/nb.po
index d66aa50263..4b6e5136b0 100644
--- a/git-gui/po/nb.po
+++ b/git-gui/po/nb.po
@@ -1462,23 +1462,6 @@ msgstr "Komprimerer objektdatabasen"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Verifiserer objektdatabasen med fsck-objects"
 
-#: lib/database.tcl:108
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database when more than %i loose objects exist.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Dette arkivet inneholder omtrent %i 'løse' objekter.\n"
-"\n"
-"For å sikre en optimal ytelse er det sterkt anbefalt at du komprimerer "
-"databasen når det er flere enn %i 'løse' objekter i den.\n"
-"\n"
-"Komprimere databasen nå?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/pt_br.po b/git-gui/po/pt_br.po
index bad116c780..8580aaaece 100644
--- a/git-gui/po/pt_br.po
+++ b/git-gui/po/pt_br.po
@@ -1541,23 +1541,6 @@ msgstr "Compactando banco de dados de objetos"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Verificando banco de dados de objetos com fsck-objects"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Este repositório possui aproximadamente %i objetos soltos.\n"
-"\n"
-"Para manter o desempenho ótimo é altamente recomendado que você compacte o "
-"banco de dados.\n"
-"\n"
-"Compactar o banco de dados agora?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/pt_pt.po b/git-gui/po/pt_pt.po
index 0ef3c7927d..e6354ce5c0 100644
--- a/git-gui/po/pt_pt.po
+++ b/git-gui/po/pt_pt.po
@@ -2537,23 +2537,6 @@ msgstr "A comprimir a base de dados de objetos"
 msgid "Verifying the object database with fsck-objects"
 msgstr "A verificar a base de dados de objetos com fsck-objects"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Este repositório tem aproximadamente %i objetos soltos.\n"
-"\n"
-"Para manter o desempenho ótimo é veemente recomendado que comprima a base de "
-"dados.\n"
-"\n"
-"Comprimir a base de dados agora?"
-
 #: lib/error.tcl:20 lib/error.tcl:116
 msgid "error"
 msgstr "erro"
diff --git a/git-gui/po/ru.po b/git-gui/po/ru.po
index 7aebaf809d..4761cc1adb 100644
--- a/git-gui/po/ru.po
+++ b/git-gui/po/ru.po
@@ -2507,16 +2507,6 @@ msgstr "Сжатие базы объектов"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Проверка базы объектов при помощи fsck"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress the database.\n"
-"\n"
-"Compress the database now?"
-msgstr "Этот репозиторий сейчас содержит примерно %i свободных объектов\n\nДля лучшей производительности рекомендуется сжать базу данных.\n\nСжать базу данных сейчас?"
-
 #: lib/error.tcl:20
 #, tcl-format
 msgid "%s: error"
diff --git a/git-gui/po/sv.po b/git-gui/po/sv.po
index de65c18584..06835f133a 100644
--- a/git-gui/po/sv.po
+++ b/git-gui/po/sv.po
@@ -1612,23 +1612,6 @@ msgstr "Komprimerar objektdatabasen"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Verifierar objektdatabasen med fsck-objects"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Arkivet har för närvarande omkring %i lösa objekt.\n"
-"\n"
-"För att bibehålla optimal prestanda rekommenderas det å det bestämdaste att "
-"du komprimerar databasen.\n"
-"\n"
-"Komprimera databasen nu?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/vi.po b/git-gui/po/vi.po
index d956b59a9e..ad0ec7816c 100644
--- a/git-gui/po/vi.po
+++ b/git-gui/po/vi.po
@@ -1598,23 +1598,6 @@ msgstr "Nén cơ sở dữ liệu đối tượng"
 msgid "Verifying the object database with fsck-objects"
 msgstr "Đang kiểm tra cơ sở dữ liệu đối tượng bằng lệnh fsck"
 
-#: lib/database.tcl:107
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"Hiện kho này mất ước chừng khoảng %i đối tượng.\n"
-"\n"
-"Để tối ưu hóa hiệu suất, khuyến nghị bạn nên nén cơ sở dữ liệu của mình "
-"lại.\n"
-"\n"
-"Nén cơ sở dữ liệu chứ?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
diff --git a/git-gui/po/zh_cn.po b/git-gui/po/zh_cn.po
index 91c1be23c2..4412d4ea44 100644
--- a/git-gui/po/zh_cn.po
+++ b/git-gui/po/zh_cn.po
@@ -1388,22 +1388,6 @@ msgstr "压缩对象数据库"
 msgid "Verifying the object database with fsck-objects"
 msgstr "使用 fsck-objects 验证对象数据库"
 
-#: lib/database.tcl:108
-#, tcl-format
-msgid ""
-"This repository currently has approximately %i loose objects.\n"
-"\n"
-"To maintain optimal performance it is strongly recommended that you compress "
-"the database when more than %i loose objects exist.\n"
-"\n"
-"Compress the database now?"
-msgstr ""
-"该版本库当前约有 %i 个松散对象.\n"
-"\n"
-"为达到较优的性能，强烈建议你在松散对象多于 %i 时压缩数据库.\n"
-"\n"
-"现在就压缩数据库么?"
-
 #: lib/date.tcl:25
 #, tcl-format
 msgid "Invalid date from Git: %s"
-- 
2.52.0