HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

git commit-graph — Write and verify Git commit-graph files. More information: <https://git-scm.com/docs/git-commit-grap

Submitted by: @import:tldr-pages··
0
Viewed 0 times
commandandcommitcliwritegit commit-graphgitverify

Problem

How to use the git commit-graph command: Write and verify Git commit-graph files. More information: <https://git-scm.com/docs/git-commit-graph>.

Solution

git commit-graph — Write and verify Git commit-graph files. More information: <https://git-scm.com/docs/git-commit-graph>.

Write a commit-graph file for the packed commits in the repository's local .git directory:
git commit-graph write


Write a commit-graph file containing all reachable commits:
git show-ref {{[-s|--hash]}} | git commit-graph write --stdin-commits


Write a commit-graph file containing all commits in the current commit-graph file along with those reachable from HEAD:
git rev-parse {{HEAD}} | git commit-graph write --stdin-commits --append

Code Snippets

Write a commit-graph file for the packed commits in the repository's local `.git` directory

git commit-graph write

Write a commit-graph file containing all reachable commits

git show-ref {{[-s|--hash]}} | git commit-graph write --stdin-commits

Write a commit-graph file containing all commits in the current commit-graph file along with those reachable from `HEAD`

git rev-parse {{HEAD}} | git commit-graph write --stdin-commits --append

Context

tldr-pages: common/git commit-graph

Revisions (0)

No revisions yet.