Hi,

say I got a file called "asdf" somewhere in a subdirectory. I can do:

git diff other_branch -- \*asdf

and it will show me the diff *only* of that file (which is the only one
that matches), so it works as expected. But if I do on the other hand:

git checkout other_branch -- \*asdf

I get: error: pathspec '*asdf' did not match any file(s) known to git.

which is not what I'm expecting. I figure this is due to the fact that
diff does not use parse_pathspec() but handles paths diffently (not
sure though)? I'd kind of find it useful to be able to 'git checkout
some_branch -- \*.txt' to get all differing text files from another
branch for example.

Cheers
Constantin
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to