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

Re: [PATCH v4] Teach git to change to a given directory using -C option

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 19, 2013, 17:13 UTC
Message-ID
<xmqqob7ou434.fsf@gitster.dls.corp.google.com>
In-Reply-To
<20130919131854.GA19790@gmail.com>
Nazri Ramliy <ayiehere@gmail.com> writes:
> Now I'm noticing that you've already made the above fixes in next ;)
Yes.  I said I'd locally tweak and queue, didn't I?
Show 10 quoted lines
>>> +test_expect_success '"git -C <path>" runs git from the directory <path>' '
>>> +     test_create_repo dir1 &&
>>> +     echo 1 >dir1/a.txt &&
>>> +     (cd dir1 && git add a.txt && git commit -m "initial in dir1") &&
>>
>> Curious why this does not use -C here.
>
> It didn't use -C there because it's in the "prepare the expected test
> output" stage and we want that to succeed, whether -C works or not - we
> haven't reached the part where we are actually testing the -C option,
Good thinking.
Will queue as an incremental update on top of what is already in 'next'.
Thanks.
Previous: Nazri Ramliy
Message 2 of 2 in “Teach git to change to a given directory using -C option”
  1. Teach git to change to a given directory using -C optionNazri Ramliy, Sep 19, 2013
  2. Junio C HamanoSep 19, 2013

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.