Last active
May 25, 2018 02:59
-
-
Save hangox/bac89d813dfb99753383e294f0af606d to your computer and use it in GitHub Desktop.
Git打包命令
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
简单的用法就是 | |
git archive --format zip --output /path/to/file.zip master # 将 master 以zip格式打包到指定文件 | |
还有个更简单的 | |
git archive v0.1 | gzip > site.tgz | |
git archive master > /home/hainuo/fds.zip | |
还有一个增量的 | |
git archive develop $( git diff v1.1.8_beta13..v1.1.8_beta14 --name-only)|gzip >aaa.zip #比较两个版本之间的差异文件,生成一个差异文件压缩包 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
打包之后无法使用压缩工具(
7-zip
)正常解压。