Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 1 | git-tar-tree(1) |
| 2 | =============== |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | git-tar-tree - Creates a tar archive of the files in the named tree |
| 7 | |
| 8 | |
| 9 | SYNOPSIS |
| 10 | -------- |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 11 | 'git-tar-tree' [--remote=<repo>] <tree-ish> [ <base> ] |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 12 | |
| 13 | DESCRIPTION |
| 14 | ----------- |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 15 | THIS COMMAND IS DEPRECATED. Use `git-archive` with `--format=tar` |
| 16 | option instead. |
| 17 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 18 | Creates a tar archive containing the tree structure for the named tree. |
| 19 | When <base> is specified it is added as a leading path to the files in the |
| 20 | generated tar archive. |
| 21 | |
| 22 | git-tar-tree behaves differently when given a tree ID versus when given |
| 23 | a commit ID or tag ID. In the first case the current time is used as |
| 24 | modification time of each file in the archive. In the latter case the |
| 25 | commit time as recorded in the referenced commit object is used instead. |
| 26 | Additionally the commit ID is stored in a global extended pax header. |
| 27 | It can be extracted using git-get-tar-commit-id. |
| 28 | |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 29 | OPTIONS |
| 30 | ------- |
| 31 | |
| 32 | <tree-ish>:: |
| 33 | The tree or commit to produce tar archive for. If it is |
| 34 | the object name of a commit object. |
| 35 | |
| 36 | <base>:: |
| 37 | Leading path to the files in the resulting tar archive. |
| 38 | |
| 39 | --remote=<repo>:: |
| 40 | Instead of making a tar archive from local repository, |
| 41 | retrieve a tar archive from a remote repository. |
| 42 | |
Junio C Hamano | 75cc4c9 | 2006-07-24 08:25:03 | [diff] [blame] | 43 | CONFIGURATION |
| 44 | ------------- |
| 45 | By default, file and directories modes are set to 0666 or 0777. It is |
| 46 | possible to change this by setting the "umask" variable in the |
| 47 | repository configuration as follows : |
| 48 | |
| 49 | [tar] |
| 50 | umask = 002 ;# group friendly |
| 51 | |
| 52 | The special umask value "user" indicates that the user's current umask |
| 53 | will be used instead. The default value remains 0, which means world |
| 54 | readable/writable files and directories. |
| 55 | |
| 56 | EXAMPLES |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 57 | -------- |
Junio C Hamano | 74bbe90 | 2006-06-18 11:37:24 | [diff] [blame] | 58 | git tar-tree HEAD junk | (cd /var/tmp/ && tar xf -):: |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 59 | |
| 60 | Create a tar archive that contains the contents of the |
| 61 | latest commit on the current branch, and extracts it in |
| 62 | `/var/tmp/junk` directory. |
| 63 | |
Junio C Hamano | 74bbe90 | 2006-06-18 11:37:24 | [diff] [blame] | 64 | git tar-tree v1.4.0 git-1.4.0 | gzip >git-1.4.0.tar.gz:: |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 65 | |
Junio C Hamano | 74bbe90 | 2006-06-18 11:37:24 | [diff] [blame] | 66 | Create a tarball for v1.4.0 release. |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 67 | |
Junio C Hamano | 74bbe90 | 2006-06-18 11:37:24 | [diff] [blame] | 68 | git tar-tree v1.4.0{caret}\{tree\} git-1.4.0 | gzip >git-1.4.0.tar.gz:: |
Junio C Hamano | 33db437 | 2006-06-07 19:51:45 | [diff] [blame] | 69 | |
Junio C Hamano | 74bbe90 | 2006-06-18 11:37:24 | [diff] [blame] | 70 | Create a tarball for v1.4.0 release, but without a |
| 71 | global extended pax header. |
| 72 | |
| 73 | git tar-tree --remote=example.com:git.git v1.4.0 >git-1.4.0.tar:: |
| 74 | |
| 75 | Get a tarball v1.4.0 from example.com. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 76 | |
Junio C Hamano | c99ab98 | 2006-07-31 08:45:12 | [diff] [blame] | 77 | git tar-tree HEAD:Documentation/ git-docs > git-1.4.0-docs.tar:: |
| 78 | |
| 79 | Put everything in the current head's Documentation/ directory |
| 80 | into 'git-1.4.0-docs.tar', with the prefix 'git-docs/'. |
| 81 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 82 | Author |
| 83 | ------ |
| 84 | Written by Rene Scharfe. |
| 85 | |
| 86 | Documentation |
| 87 | -------------- |
| 88 | Documentation by David Greaves, Junio C Hamano and the git-list <git@vger.kernel.org>. |
| 89 | |
| 90 | GIT |
| 91 | --- |
| 92 | Part of the gitlink:git[7] suite |
| 93 | |