From ed20cae0f7e0bb66791219ba1127346a960c534c Mon Sep 17 00:00:00 2001 From: ivuorinen Date: Wed, 20 Mar 2024 00:12:50 +0000 Subject: [PATCH] Update cheatsheets --- tldr/git-mktree | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 tldr/git-mktree diff --git a/tldr/git-mktree b/tldr/git-mktree new file mode 100644 index 00000000..3026a681 --- /dev/null +++ b/tldr/git-mktree @@ -0,0 +1,29 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# git mktree + +> Build a tree object using `ls-tree` formatted text. +> More information: . + +- Build a tree object and verify that each tree entry’s hash identifies an existing object: + +`git mktree` + +- Allow missing objects: + +`git mktree --missing` + +- Read the NUL ([z]ero character) terminated output of the tree object (`ls-tree -z`): + +`git mktree -z` + +- Allow the creation of multiple tree objects: + +`git mktree --batch` + +- Sort and build a tree from `stdin` (non-recursive `git ls-tree` output format is required): + +`git mktree < {{path/to/tree.txt}}`