Created
June 19, 2014 19:02
-
-
Save GLips/4a16a260c798a58c909d to your computer and use it in GitHub Desktop.
Automatically tar up changed files between two different commits—e.g. `mpackager HEAD HEAD^` to tar up all the files changed in the most recent commit.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
git diff $1 $2 --name-only > updates.txt | |
tar zcf updates.tgz --files-from=updates.txt | |
rm updates.txt | |
echo "Created file updates.tgz with the following files:" | |
tar -tf updates.tgz |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment