I\'ve a directory structure like this:
root/
.git
deploy/
Site/
blah/
more_blah/
something.local
else.development
Rakefile
For directories I had problems with different versions of git, so I had to include an entry both with and without a training slash:
Where foo/bar is relative to the where I ran git archive, but the actual .gitattributes was in the project root directory in addition to --worktree-attributes as noted above.