chiark / gitweb /
dgit: Turn gc.auto off in our hidden working tree setups
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 24 Sep 2016 10:19:42 +0000 (11:19 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 26 Sep 2016 00:16:54 +0000 (01:16 +0100)
This avoids potential accidents: git gc --auto might otherwise run and
do very undesirable things to the user's working tree.  (I haven't
been able to trigger such a situation deliberately and none has been
reported, luckily...)

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
debian/changelog
dgit

index ee5f7d0b5b56748199a6ae383f22ecac7e685669..7143fe7d5b222cbc6782efd41e20e36fa1e371fe 100644 (file)
@@ -48,6 +48,7 @@ dgit (1.5~~) unstable; urgency=medium
     source.  Fixes bad Perl poetry syntax.  Closes:#829121.
   * When synthesing a commit from a .dsc from the archive, stop
     internal git reset from printing a confusing message about HEAD.
+  * Turn off git gc in the private working areas.
 
   Test suite:
   * When sbuild fails, do not crash due to sed not finding the log
diff --git a/dgit b/dgit
index 39efa04a2189491f45441039c45f2320c1a22ad4..b1cb9b25dabb8516baa5356817864a62608bbdba 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -1340,6 +1340,7 @@ sub prep_ud (;$) {
 
 sub mktree_in_ud_here () {
     runcmd qw(git init -q);
+    runcmd qw(git config gc.auto 0);
     rmtree('.git/objects');
     symlink '../../../../objects','.git/objects' or die $!;
 }