# [GSoC] Inquiry about writing config file to disk

2 messages from 2014-03-20 to 2014-03-21. Participants: Tanay Abhra, Jeff King.
Thread: https://gitlist.dev/t/36252

## Tanay Abhra, 2014-03-20 17:25

Subject: [GSoC] Inquiry about writing config file to disk
Message-ID: <loom.20140320T181941-0@post.gmane.org>
URL: https://gitlist.dev/e/loom.20140320T181941-0%40post.gmane.org

```
Hi,

I have gone through commit.c, builtin/commit.c and api-config.txt but one
thing I cannot find is which functions handle writing config file to disk
after adding a new variable,value pair(for example git config my.option
true) . It is also marked TODO on the api-config.txt file. Can somebody help
me , I just want the starting function and will trace the function calls
after that.

Regards,
Tanay Abhra.

```

## Jeff King, 2014-03-21 05:19

Subject: Re: [GSoC] Inquiry about writing config file to disk
Message-ID: <20140321051941.GA31161@sigill.intra.peff.net>
URL: https://gitlist.dev/e/20140321051941.GA31161%40sigill.intra.peff.net
In-Reply-To: <loom.20140320T181941-0@post.gmane.org>

```
On Thu, Mar 20, 2014 at 05:25:22PM +0000, Tanay Abhra wrote:

> I have gone through commit.c, builtin/commit.c and api-config.txt but one
> thing I cannot find is which functions handle writing config file to disk
> after adding a new variable,value pair(for example git config my.option
> true) . It is also marked TODO on the api-config.txt file. Can somebody help
> me , I just want the starting function and will trace the function calls
> after that.

Try starting in cmd_config (in builtin/config.c), the main entry point
for running "git config", and you should be able to trace it from there.

The main logic ends up in the git_config_set_* functions.

-Peff

```
