* Support -- pathspec in git-stash show command
@ 2022-05-02 16:01 Erik Aigner
0 siblings, 0 replies; only message in thread
From: Erik Aigner @ 2022-05-02 16:01 UTC (permalink / raw)
To: git
Thank you for filling out a Git bug report!
Please answer the following questions to help us understand your issue.
What did you do before the bug happened? (Steps to reproduce your issue)
1) Create a stash containing multiple files including `foo/bar.txt`
2) perform `git stash show -p stash@{0} -- foo/bar.txt
What did you expect to happen? (Expected behavior)
The stash patch output would be limited to only the provided pathspec `foo/bar.txt`
What happened instead? (Actual behavior)
Error message "Too many revisions specified: 'stash@{0}' 'test/foo.txt'"
What's different between what you expected and what actually happened?
The manpage for git-stash states that the SHOW command should support any argument the git-diff command also accepts,
but apparently the trailing "-- <pathspec>" does not work with "git stash show".
Anything else you want to add:
For symmetry with git-diff, git-show should also support a pathspec parameter. The reason for this is that `git stash show`
has the stash specific `--include-untracked` paramenter, which git-diff doesn't have.
Please review the rest of the bug report below.
You can delete any lines you don't wish to share.
[System Info]
git version:
git version 2.32.0 (Apple Git-132)
cpu: arm64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
shell-path: /bin/sh
uname: Darwin 21.4.0 Darwin Kernel Version 21.4.0: Fri Mar 18 00:47:26 PDT 2022; root:xnu-8020.101.4~15/RELEASE_ARM64_T8101 arm64
compiler info: clang: 13.1.6 (clang-1316.0.21.2.3)
libc info: no libc information available
$SHELL (typically, interactive shell): /bin/zsh
[Enabled Hooks]
pre-commit
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-05-02 16:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-02 16:01 Support -- pathspec in git-stash show command Erik Aigner
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).