(c commitgraph.CommitNode, treePath string)
| 103 | } |
| 104 | |
| 105 | func getCommitTree(c commitgraph.CommitNode, treePath string) (*object.Tree, error) { |
| 106 | tree, err := c.Tree() |
| 107 | if err != nil { |
| 108 | return nil, err |
| 109 | } |
| 110 | |
| 111 | // Optimize deep traversals by focusing only on the specific tree |
| 112 | if treePath != "" { |
| 113 | tree, err = tree.Tree(treePath) |
| 114 | if err != nil { |
| 115 | return nil, err |
| 116 | } |
| 117 | } |
| 118 | |
| 119 | return tree, nil |
| 120 | } |
| 121 | |
| 122 | func getFullPath(treePath, path string) string { |
| 123 | if treePath != "" { |
no test coverage detected
searching dependent graphs…