-
-
Save andjc/a833fe1dc9799fad7bc416f059b9d8f1 to your computer and use it in GitHub Desktop.
gitzip -- create a zip file of a git project
This file contains hidden or 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 | |
## | |
## I usually put this in my .bashrc | |
## | |
## When in a git project dir, run 'gitzip foo' to get a 'foo.zip' in the parent | |
## directory. | |
gitzip() { git archive HEAD --format=zip --prefix="$*/" > ../"$*.zip"; } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment