Re: [GSOC 2014]idea:Git Configuration API Improvement
- From
Michael Haggerty <mhagger@alum.mit.edu>
- Date
- Mar 20, 2014, 08:47 UTC
- Message-ID
- <532AAB39.3010507@alum.mit.edu>
- In-Reply-To
- <1395300220-7540-1-git-send-email-zhaox383@umn.edu>
On 03/20/2014 08:23 AM, Yao Zhao wrote:
> Third one is about when to write back to file, I am really confused > about it. I think one way could be when user leave git repository > using "cd" to go back. But I am not sure if git could detect user > calls "cd" to leave repository.
I don't understand. The cache would be in memory, and would only live as long as a single "git" process. Within that process, if somebody wants to change the config, they might (for example) call one function to lock the config file, a second function to change the value(s) in memory, and then a third function to flush the new config out to disk and unlock the config file again. The cache would usually only live for milliseconds, not minutes/hours, so I don't think your question really makes sense.
Michael
-- Michael Haggerty mhagger@alum.mit.edu http://softwareswirl.blogspot.com/