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

Re: Git branch outputs usage message on stderr

From
KHKristoffer Haugsbakk <kristofferhaugsbakk@fastmail.com>
Date
Jan 15, 2025, 16:55 UTC
Message-ID
<c92e7b16-b70d-46f3-9858-2be805c5285f@app.fastmail.com>
In-Reply-To
<xmqqed1414gt.fsf@gitster.g>
On Wed, Jan 15, 2025, at 16:28, Junio C Hamano wrote:
> Somebody may want to go over "git help --all" and for each of them
> try "git $cmd -h >/dev/null" to find those that give the help output
> to their standard error stream.
    #!/bin/sh
    for cmd in $(git --list-cmds=builtins); do
        git $cmd -h >/dev/null
    done 2>&1 | grep '^usage: ' \
        | perl -pe 's/^usage:\s*(\(EXPERIMENTAL!\)\s*)?//; s/^(git\s+[a-zA-Z0-9-]+).*/\1/'
Gives
    git am
    git branch
    git check-ref-format
    git checkout--worker
    git checkout-index
    git commit
    git commit-tree
    git credential
    git diff
    git diff-files
    git diff-index
    git diff-tree
    git fast-import
    git fetch-pack
    git fsmonitor--daemon
    git gc
    git get-tar-commit-id
    git index-pack
    git ls-files
    git mailsplit
    git merge
    git merge-index
    git merge-ours
    git merge-recursive
    git merge-recursive-ours
    git merge-recursive-theirs
    git merge-subtree
    git pack-redundant
    git rebase
    git remote-ext
    git remote-fd
    git rev-list
    git rev-parse
    git status
    git unpack-file
    git unpack-objects
    git update-index
    git upload-archive
    git upload-archive
    git var
For
    $ git version
    git version 2.48.0
Previous: Junio C HamanoNext: Jeff King
Message 5 of 27 in “Git branch outputs usage message on stderr”
  1. Jonas KonradJan 15, 2025
  2. Matěj CeplJan 15, 2025
  3. Jonas KonradJan 15, 2025
  4. Junio C HamanoJan 15, 2025
  5. Kristoffer HaugsbakkJan 15, 2025
  6. Jeff KingJan 15, 2025
  7. Junio C HamanoJan 15, 2025
  8. Junio C HamanoJan 15, 2025
  9. Jeff KingJan 15, 2025
  10. Junio C HamanoJan 15, 2025
  11. Jeff KingJan 15, 2025
  12. Junio C HamanoJan 15, 2025
  13. Jeff KingJan 15, 2025
  14. Junio C HamanoJan 15, 2025
  15. Junio C HamanoJan 16, 2025
  16. Jeff KingJan 16, 2025
  17. Junio C HamanoJan 15, 2025
  18. Jeff KingJan 15, 2025
  19. Junio C HamanoJan 15, 2025
  20. Junio C HamanoJan 15, 2025
  21. Kristoffer HaugsbakkJan 15, 2025
  22. Junio C HamanoJan 15, 2025
  23. Jonas KonradJan 15, 2025
  24. Kristoffer HaugsbakkJan 15, 2025
  25. Junio C HamanoJan 15, 2025
  26. Kristoffer HaugsbakkJan 15, 2025
  27. Junio C HamanoJan 15, 2025

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.