Git features the git archive command to export the status of the complete repository at a given time.

Tags are important when a specific revision is exported from the repository. These tags are specially marked points along the development time axis. In the Linux context, these points in time represent the published versions of the kernel. For example, the tag for version 2.6.24 is v2.6.24. This symbolic identifier can be used as an abbreviation for the usual combination of digits because it is much easier to remember. The use of tags to identify releases is a Linus Torvalds convention for the Linux sources. Tags can, of course, be used for many other purposes; for example, to mark the beginning or end of far-reaching changes, or to identify interim versions.

Figure B-7: Inspecting commits with qgit.

The following input is necessary to export the entire source code of the named version into a separate directory:

[email protected]> git archive --format=tar --prefix=linux-2.6.24/ v2.6.24

Because this will write the resulting tarball to the standard output, you might want to redirect the result to a file.

git archive can also be used to generate different types of archives. A filename with the suffix .tar.gz, .tgz, or .tar.bz2 must be used instead of the tar file shown here.

Continue reading here: B5 Debugging and Analyzing the Kernel

Was this article helpful?

0 0