From: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
To: git <git@vger.kernel.org>
Cc: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Subject: "git gc" leaving gc.pid files around
Date: Wed, 25 Sep 2013 20:29:50 +0200 [thread overview]
Message-ID: <vpqzjr0rbz5.fsf@anie.imag.fr> (raw)
Hi,
Since 64a99eb47, "git gc" creates a lock file gc.pid while running. I
just noticed that the file is never deleted. The locking mechanism
works, but leaving these files around creates a minor annoyance.
For example, I run "git gc" in all my repos from time to time (in a cron
job). It normally does nothing in repos that have not changed, but now,
it updates the gc.pid file.
As a result, all the gc.pid files show up in unison (synchronization
tool between machines) for example.
Is there any reason not to do something like this:
--- a/builtin/gc.c
+++ b/builtin/gc.c
@@ -316,5 +316,6 @@ int cmd_gc(int argc, const char **argv, const char *prefix)
warning(_("There are too many unreachable loose objects; "
"run 'git prune' to remove them."));
+ unlink(git_path("gc.pid"));
return 0;
}
?
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
next reply other threads:[~2013-09-25 18:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-25 18:29 Matthieu Moy [this message]
2013-09-25 19:06 ` "git gc" leaving gc.pid files around Duy Nguyen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=vpqzjr0rbz5.fsf@anie.imag.fr \
--to=matthieu.moy@grenoble-inp.fr \
--cc=git@vger.kernel.org \
--cc=pclouds@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox