Skip to content

Latest commit

 

History

History
22 lines (16 loc) · 356 Bytes

index.md

File metadata and controls

22 lines (16 loc) · 356 Bytes

git archive

Create an archive file of everything in the repo

Git alias:

archive = !"f() { \
    top=$(rev-parse --show-toplevel); \
    cd $top; \
    tar cvf $top.tar $top ; \
}; f"

Example:

git archive

This archive can be useful for backups, disaster recovery, legal auditing, or sending the repo as a file to someone.