If I want to replace a folder on a working branch with the same folder from another branch, I can call:
git checkout OTHER_BRANCH -- /path/to/folder
what is the meaning of the -- ?
Everything after -- is considered a file name. This is useful in at least two cases:
git checkout foo -- and git checkout -- foo
git checkout -- -f (alternatively: git checkout ./-f If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With