Junio C Hamano | 54559c8 | 2006-04-13 07:45:12 | [diff] [blame] | 1 | git-mktree(1) |
| 2 | ============= |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | git-mktree - Build a tree-object from ls-tree formatted text |
| 7 | |
| 8 | |
| 9 | SYNOPSIS |
| 10 | -------- |
Junio C Hamano | 15567bc | 2011-07-23 00:51:59 | [diff] [blame] | 11 | [verse] |
Junio C Hamano | 3d14151 | 2009-06-01 01:22:40 | [diff] [blame] | 12 | 'git mktree' [-z] [--missing] [--batch] |
Junio C Hamano | 54559c8 | 2006-04-13 07:45:12 | [diff] [blame] | 13 | |
| 14 | DESCRIPTION |
| 15 | ----------- |
Junio C Hamano | 3d14151 | 2009-06-01 01:22:40 | [diff] [blame] | 16 | Reads standard input in non-recursive `ls-tree` output format, and creates |
Junio C Hamano | 96153bf | 2018-04-25 08:25:34 | [diff] [blame] | 17 | a tree object. The order of the tree entries is normalized by mktree so |
Junio C Hamano | 3d14151 | 2009-06-01 01:22:40 | [diff] [blame] | 18 | pre-sorting the input is not required. The object name of the tree object |
Junio C Hamano | 54559c8 | 2006-04-13 07:45:12 | [diff] [blame] | 19 | built is written to the standard output. |
| 20 | |
| 21 | OPTIONS |
| 22 | ------- |
| 23 | -z:: |
| 24 | Read the NUL-terminated `ls-tree -z` output instead. |
| 25 | |
Junio C Hamano | 3d14151 | 2009-06-01 01:22:40 | [diff] [blame] | 26 | --missing:: |
| 27 | Allow missing objects. The default behaviour (without this option) |
| 28 | is to verify that each tree entry's sha1 identifies an existing |
| 29 | object. This option has no effect on the treatment of gitlink entries |
| 30 | (aka "submodules") which are always allowed to be missing. |
| 31 | |
| 32 | --batch:: |
| 33 | Allow building of more than one tree object before exiting. Each |
| 34 | tree is separated by as single blank line. The final new-line is |
Junio C Hamano | 92d8037 | 2016-07-13 22:00:05 | [diff] [blame] | 35 | optional. Note - if the `-z` option is used, lines are terminated |
Junio C Hamano | 3d14151 | 2009-06-01 01:22:40 | [diff] [blame] | 36 | with NUL. |
| 37 | |
Junio C Hamano | 54559c8 | 2006-04-13 07:45:12 | [diff] [blame] | 38 | GIT |
| 39 | --- |
Junio C Hamano | f7c042d | 2008-06-06 22:50:53 | [diff] [blame] | 40 | Part of the linkgit:git[1] suite |