Re: git-credential-cache--daemon quits on SIGHUP, can we change it to ignore instead?
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Oct 27, 2015, 17:52 UTC
- Message-ID
- <xmqqoafkci6j.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <20151026215016.GA17419@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 10 quoted lines
> But these days, people often have several simultaneous sessions open. > They may have multiple ssh sessions to a single machine, or they may > have a bunch of terminal windows open, each of which has a login shell > and will send HUP to its children when it exits. In that case, you have > a meta-session surrounding those individual terminal sessions, and you > probably do want to keep the cache going as long as the meta session[1]. > ... > [1] Of course we have no idea when that meta-session is closed. But if > you have a script that runs on X logout, for instance, you could put > "git credential-cache exit" in it.
Yes. Probably the right way forward is to make it a non-issue by teaching users how to control the lifetime of the "daemon" process, and wean them off relying on "it is auto-spawned if you forgot to start", as that convenience of auto-spawning is associated with "...but how it is auto-shutdown really depends on many things in your specific environment", which is the issue.