summaryrefslogtreecommitdiff
path: root/t/t7521-ignored-mode.sh
diff options
context:
space:
mode:
authorLibravatar Teng Long <dyroneteng@gmail.com>2022-01-17 16:21:01 +0800
committerLibravatar Junio C Hamano <gitster@pobox.com>2022-01-17 11:42:25 -0800
commitc11f95010cc9f09ea3e5d401bc14c9b6663d2893 (patch)
tree851edb82f3594a1fb3a851bbd4a5d5edde13e3f3 /t/t7521-ignored-mode.sh
parentGit 2.34.1 (diff)
downloadtgif-c11f95010cc9f09ea3e5d401bc14c9b6663d2893.tar.xz
git-cli.txt: clarify "options first and then args"
There are some commands permit the user whether to provide options first before args, or the reverse order. For example: git push --dry-run <remote> <ref> And: git push <remote> <ref> --dry-run Both of them is supported, but some commands do not, for instance: git ls-remote --heads <remote> And: git ls-remote <remote> --heads If <remote> only has one ref and it's name is "refs/heads/--heads", you will get the same result, otherwise will not.This is because the former in the second example will parse "--heads" as an "option" which means to limit to only "refs/heads" when listing the remote references, the latter treat "--heads" as an argument which means to filter the result list with the given pattern. Therefore, we want to specify a bit more in "gitcli.txt" about the way we recommend and help to resolve the ambiguity around some git command usage. The related disscussions locate at [1]. By the way, there are some issues with lowercase letters in the document, which have been modified together. [1] https://public-inbox.org/git/cover.1642129840.git.dyroneteng@gmail.com/ Signed-off-by: Teng Long <dyroneteng@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7521-ignored-mode.sh')
0 files changed, 0 insertions, 0 deletions