git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [[GSOC][PATCH v3] 3/3] docs: replace git_config with repo_config

From
JAYATHEERTH K <jayatheerthkulkarni2005@gmail.com>
Date
Mar 24, 2025, 01:42 UTC
Message-ID
<CA+rGoLfALoTvQuAzQPx7rqd-Zy+wMiyEbF5Y8_-2Yi-yE-2qpA@mail.gmail.com>
In-Reply-To
<xmqqiknzqu2h.fsf@gitster.g>
On Mon, Mar 24, 2025 at 3:38 AM Junio C Hamano <gitster@pobox.com> wrote:
Show 33 quoted lines
>
> K Jayatheerth <jayatheerthkulkarni2005@gmail.com> writes:
>
> > Refactor config handling by replacing git_config(...)
> > with repo_config(...) for better repository context
> > awareness and alignment with modern Git practices.
> >
> > Signed-off-by: K Jayatheerth <jayatheerthkulkarni2005@gmail.com>
> > ---
> >  Documentation/MyFirstContribution.adoc | 57 ++++++++++++++++++--------
> >  1 file changed, 39 insertions(+), 18 deletions(-)
> >
> > diff --git a/Documentation/MyFirstContribution.adoc b/Documentation/MyFirstContribution.adoc
> > index 45efe117ab..3ae85016d4 100644
> > --- a/Documentation/MyFirstContribution.adoc
> > +++ b/Documentation/MyFirstContribution.adoc
> > @@ -316,26 +316,47 @@ on the command line, including the name of our command. (If `prefix` is empty
> >  for you, try `cd Documentation/ && ../bin-wrappers/git psuh`). That's not so
> >  helpful. So what other context can we get?
> >
> > -Add a line to `#include "config.h"`. Then, add the following bits to the
> > +Add `#include "config.h"` and `#include "repository.h"`. Then, add the following bits to the
> >  function body:
> >
> >  ----
> > -     const char *cfg_name;
> > +#include "builtin.h"
> > +#include "gettext.h"
> > +#include "config.h"
> > +#include "repository.h"  // Required for repo_config_get_string_tmp()
>
> I do not think we updated Coding Guidelines to allow // comments.
>

Since this was a tutorial I thought this was helpful, anyways I will remove the comments, because I get that this would be bad practice for newbies.

Previous: Junio C HamanoNext: Junio C Hamano
Message 13 of 21 in “Remove outdated mentoring mailing list reference and clarify tutorial prerequisites”
  1. K JayatheerthMar 15, 2025
  2. [GSOC][PATCH 2/3] Update function signature and UNUSED to include struct repository and modify builtin.h accordinglyK Jayatheerth, Mar 15, 2025
  3. [GSOC][PATCH 3/3] Replace git_config(...) with repo_config(...) for modern Git compatibilityK Jayatheerth, Mar 15, 2025
  4. JAYATHEERTH KMar 15, 2025
  5. Junio C HamanoMar 17, 2025
  6. [GSOC][PATCH v2] Remove outdated mentoring mailing list referenceK Jayatheerth, Mar 19, 2025
  7. Junio C HamanoMar 21, 2025
  8. [[GSOC][PATCH v3] 1/3] docs: drop inactive mentoring list, add C prereqK Jayatheerth, Mar 21, 2025
  9. [[GSOC][PATCH v3] 2/3] docs: update function signature, add UNUSED macroK Jayatheerth, Mar 21, 2025
  10. Junio C HamanoMar 23, 2025
  11. [[GSOC][PATCH v3] 3/3] docs: replace git_config with repo_configK Jayatheerth, Mar 21, 2025
  12. Junio C HamanoMar 23, 2025
  13. JAYATHEERTH KMar 24, 2025
  14. Junio C HamanoMar 24, 2025
  15. [[GSOC][PATCH v4] 2/3] docs: update function signature, add UNUSED macroK Jayatheerth, Mar 24, 2025
  16. [[GSOC][PATCH v4] 3/3] docs: replace git_config with repo_configK Jayatheerth, Mar 24, 2025
  17. JAYATHEERTH KMar 24, 2025
  18. Junio C HamanoMar 26, 2025
  19. JAYATHEERTH KMar 26, 2025
  20. JAYATHEERTH KMar 29, 2025
  21. JAYATHEERTH KMar 21, 2025

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.