Last active
November 20, 2015 12:54
-
-
Save nasitra/a5288d35a32a7137a517 to your computer and use it in GitHub Desktop.
Make changed files between master branch and current branch
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
git archive --format=zip --prefix=master/ master `git diff --name-only HEAD master` -o master.zip | |
git archive --format=zip --prefix=current/ HEAD `git diff --name-only HEAD master` -o current.zip |
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
set COMMAND_FILE= __command__.txt | |
for /f "usebackq tokens=*" %a in (`git diff --name-only HEAD master`) do set /p NOLINEBREAK=%a <NUL >> %COMMAND_FILE% | |
for /f "usebackq tokens=*" %a in (`type %COMMAND_FILE%`) do git archive --format=zip --prefix=master/ master %a -o master.zip | |
for /f "usebackq tokens=*" %a in (`type %COMMAND_FILE%`) do git archive --format=zip --prefix=current/ HEAD %a -o current.zip | |
del %COMMAND_FILE% |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment