As you are not trying to move the files around in the tree, you should be able to just checkout the directory:
git checkout master -- dirname
As you are not trying to move the files around in the tree, you should be able to just checkout the directory:
git checkout master -- dirname