Git: copy all files in a directory from another branch
How do I copy all files in a directory from another branch? I can list all of the files in that directory by doing 

<code>
git ls-tree master:dirname
</code>

I can then copy all of the files individually by doing

<code>
git checkout master -- dirname/filename
</code>

However, using wildcards has so far been a total fail. <code> git checkout master -- dirname/*.png </code> does nothing. Though I guess I can use a bash script to do that, there has to be an easier way, right?
Git: copy all files in a directory from another branch
===

How do I copy all files in a directory from another branch? I can list all of the files in that directory by doing 

<code>
git ls-tree master:dirname
</code>

I can then copy all of the files individually by doing

<code>
git checkout master -- dirname/filename
</code>

However, using wildcards has so far been a total fail. <code> git checkout master -- dirname/*.png </code> does nothing. Though I guess I can use a bash script to do that, there has to be an easier way, right?