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

rev-parse -q --verify with not existent upstream branch

From
Kacper Kornet <draenog@pld-linux.org>
Date
Aug 31, 2012, 17:11 UTC
Message-ID
<20120831171158.GM21362@camk.edu.pl>
Documentation to git-rev-parse claims that
-q, --quiet
   Only meaningful in --verify mode. Do not output an error
   message if the first argument is not a valid object name; instead exit
   with non-zero status silently.

However when I try to check if the current branch has a configured upstream one with:

git rev-parse -q --verify  '@{u}'
I still receives the error message:
error: No upstream configured for branch 'threading'

Additinally withour -q --verify options the error message is printed twice:

error: No upstream configured for branch 'threading' @{u} error: No upstream configured for branch 'threading' fatal: ambiguous argument '@{u}': unknown revision or path not in the working tree. Use '--' to separate paths from revision

-- 
  Kacper
Message 1 of 1 in “rev-parse -q --verify with not existent upstream branch”
  1. Kacper KornetAug 31, 2012

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.