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

`git fetch origin ''` (the empty string) -- should this work?

From
Anthony Sottile <asottile@umich.edu>
Date
Jan 8, 2020, 05:28 UTC
Message-ID
<CA+dzEBnT2Bgw7iwVWiHyCKs1V1oaSuEb8rR+dmiO7RbqpaVjgw@mail.gmail.com>

this seems to end up doing the same as `git fetch origin HEAD` but I can't figure out why -- perhaps someone on this list can help me :)

$ git fetch origin ''
From github.com:python/cpython
 * branch                  HEAD       -> FETCH_HEAD

what I expected was `fatal: Couldn't find remote ref ''` or something of the sort as would be seen when fetching some non-existent branch:

$ git fetch origin wat fatal: Couldn't find remote ref wat

Anthony
Message 1 of 1 in “`git fetch origin ''` (the empty string) -- should this work?”
  1. Anthony SottileJan 8, 2020

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.