git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Ayush Chandekar <ayu.chandekar@gmail.com>
Cc: git@vger.kernel.org,  christian.couder@gmail.com,
	shyamthakkar001@gmail.com
Subject: Re: [GSOC PATCH 2/2] builtin/fmt-merge-msg: stop depending on 'the_repository'
Date: Tue, 29 Jul 2025 15:41:27 -0700	[thread overview]
Message-ID: <xmqqh5yuoc14.fsf@gitster.g> (raw)
In-Reply-To: <CAE7as+ZUcqRbnOC11DQ7=b+YB+9HTfjfqCvxzmz+mpSH6DxkGQ@mail.gmail.com> (Ayush Chandekar's message of "Wed, 30 Jul 2025 03:19:01 +0530")

Ayush Chandekar <ayu.chandekar@gmail.com> writes:

>> It generally is a bad idea to read command line options first and
>> then read the configuration (it is a bug if such a flow causes
>> values from configuration to overwrite values from command line).
>> THe current set of options and configuration variables may not
>> overlap, in which case such a questionable arrangement happen to be
>> without bug right now, but it would prevent future developers from
>> adding new options and configuration variables and make them
>> interact with each other in the most natural way.
>
> I understand it, but how do we tackle if NULL repository is passed.

Perhaps you want to study the problem space and related past changes
before going forward.  The first place to look at is what happens
when you call repo_config(), outside a repository or a working tree
and repository is NULL.

f29f1990 (config: teach repo_config to allow `repo` to be NULL,
2025-03-08) and what it calls "the following commits" may be
illuminating.


  reply	other threads:[~2025-07-29 22:41 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-29 16:19 [GSOC PATCH 0/2] builtin/fmt-merge-msg: remove dependency on global variables and 'the_repository' Ayush Chandekar
2025-07-29 16:19 ` [GSOC PATCH 1/2] environment: remove the global variable 'merge_log_config' Ayush Chandekar
2025-07-29 16:48   ` Junio C Hamano
2025-07-29 17:30     ` Ayush Chandekar
2025-07-29 17:53       ` Junio C Hamano
2025-07-29 19:07   ` Phillip Wood
2025-07-29 21:16     ` Ayush Chandekar
2025-07-30  8:53       ` Phillip Wood
2025-07-29 16:19 ` [GSOC PATCH 2/2] builtin/fmt-merge-msg: stop depending on 'the_repository' Ayush Chandekar
2025-07-29 16:41   ` Junio C Hamano
2025-07-29 21:49     ` Ayush Chandekar
2025-07-29 22:41       ` Junio C Hamano [this message]
2025-08-10 15:33 ` [GSOC PATCH 0/2] builtin/fmt-merge-msg: remove dependency on global variables and 'the_repository' Ayush Chandekar
2025-08-10 23:45 ` [GSOC PATCH v2 " Ayush Chandekar
2025-08-10 23:45   ` [GSOC PATCH v2 1/2] environment: remove the global variable 'merge_log_config' Ayush Chandekar
2025-08-11 14:42     ` Phillip Wood
2025-08-11 16:13       ` Junio C Hamano
2025-08-11 18:25         ` Ayush Chandekar
2025-08-10 23:45   ` [GSOC PATCH v2 2/2] builtin/fmt-merge-msg: stop depending on 'the_repository' Ayush Chandekar

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=xmqqh5yuoc14.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=ayu.chandekar@gmail.com \
    --cc=christian.couder@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=shyamthakkar001@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;
as well as URLs for NNTP newsgroup(s).