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

Re: [BUG] --bare is ignored before command word

From
Jacob Keller <jacob.keller@gmail.com>
Date
Nov 18, 2015, 20:08 UTC
Message-ID
<CA+P7+xoD2-eDZQt29KBqZF2g4i+K7XhJG0mhUgqf5iDURBPntg@mail.gmail.com>
In-Reply-To
<loom.20151118T181639-5@post.gmane.org>
On Wed, Nov 18, 2015 at 9:20 AM, Ronny Borchert <mister_rs@web.de> wrote:
Show 10 quoted lines
> I was trying to clone a bare repository. Not sure why I did, maybe
> description on website was wrong.
> My try:
>
> git --bare clone https://github.....
>
> This was leading in creating a none bare repository! No error or warning
> message here!
> I guess this behavior is also for other --xxx commands.
>

This is how the git options work. Options before a command word are always ignored. It may be better to warn about these options though, so that they don't cause errors? The reasoning this is done is because options between git and its command word are used to modify general git behavior, while options after the command word modify each specific command in their own way.

Regards, Jake

Previous: Ronny BorchertNext: Matthieu Moy
Message 2 of 5 in “[BUG] --bare is ignored before command word”
  1. Ronny BorchertNov 18, 2015
  2. Jacob KellerNov 18, 2015
  3. Matthieu MoyNov 18, 2015
  4. Jeff KingNov 19, 2015
  5. Matthieu MoyNov 20, 2015

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.