Create a Repository Archive with git
Everything about git is amazing. And by "everything", I mean almost everything. As someone that used Perforce and SVN before learning git, I'm willing to ignore a few git annoyances since it makes branching and many other simple tasks easier.
One good problem I have with git is that it's so powerful I don't know all of its features.
One feature I recently found out about is its archive feature which allows for exporting an entire repository to a zip or tar file.
# Format: git archive {branchname} --format={compression} --output={filename}
git archive master --format=tar --output=kuma.tar
git archive some-feature-branch --format=tar --output=kuma.tar
Sure you could use any archiving utility to archive a given repo, this feature allows for quick archiving of any branch or repository state!
![Responsive and Infinitely Scalable JS Animations]()
Back in late 2012 it was not easy to find open source projects using requestAnimationFrame()
- this is the hook that allows Javascript code to synchronize with a web browser's native paint loop. Animations using this method can run at 60 fps and deliver fantastic...
![9 Mind-Blowing Canvas Demos]()
The <canvas>
element has been a revelation for the visual experts among our ranks. Canvas provides the means for incredible and efficient animations with the added bonus of no Flash; these developers can flash their awesome JavaScript skills instead. Here are nine unbelievable canvas demos that...
![Checkbox Filtering Using MooTools ElementFilter]()
When I first wrote MooTools ElementFilter, I didn't think much of it. Fast forward eight months later and I've realized I've used the plugin a billion times. Hell, even one of the "big 3" search engines is using it for their maps application.
![MooTools ContextMenu Plugin]()
ContextMenu is a highly customizable, compact context menu script written with CSS, XHTML, and the MooTools JavaScript framework. ContextMenu allows you to offer stylish, functional context menus on your website.
The XHTML Menu
Use a list of menu items with one link per item. The...
The title is misleading, git archive only puts the tree of a single commit into the .tar file, not the entire branch’s history. Useful for creating a tar file to release a version.
git bundle is what should be under this heading.
Hey, wouldn’t that make another nice entry?
Just a small correction:
--format
does not mean compression. It is – well – just the format of the archive, but it is not compressed at all.