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

Output of git checkout goes to stderr

From
SSSayooj Surendran <sayooj.surendran@bigbinary.com>
Date
Jul 30, 2024, 05:44 UTC
Message-ID
<CAFGW38fkr+OuhpcyqNFxZNkhNDGPxTbOmCJLVHpCGUmbj05tMg@mail.gmail.com>

Hi, Noticed that the output of git checkout command is going to stderr channel. Is this an intended behaviour? git version: 2.45.2 terminal output:

❯ git checkout -b test > stdout.txt 2> stderr.txt ❯ cat stdout.txt ❯ cat stderr.txt Switched to a new branch 'test'

Next: Eric Sunshine
Message 1 of 4 in “Output of git checkout goes to stderr”
  1. Sayooj SurendranJul 30, 2024
  2. Eric SunshineJul 30, 2024
  3. Karthik NayakJul 30, 2024
  4. Junio C HamanoJul 30, 2024

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.