1
git diff-tree -r --no-commit-id --name-only --diff-filter=ACMRT $commit_id | tar -czf file.tgz -T -

https://stackoverflow.com/questions/4541300/export-only-modified-and-added-files-with-folder-structure-in-git