mirror of
https://github.com/git/git.git
synced 2024-11-19 15:34:51 +01:00
Merge branch 'master' of git://github.com/voxpelli/git-subtree
* 'master' of git://github.com/voxpelli/git-subtree: Check that the type of the tree really is a tree and not a commit as it seems to sometimes become when eg. a submodule has existed in the same position previously.
This commit is contained in:
commit
39ee6ecf7e
1 changed files with 1 additions and 0 deletions
|
@ -322,6 +322,7 @@ subtree_for_commit()
|
||||||
git ls-tree "$commit" -- "$dir" |
|
git ls-tree "$commit" -- "$dir" |
|
||||||
while read mode type tree name; do
|
while read mode type tree name; do
|
||||||
assert [ "$name" = "$dir" ]
|
assert [ "$name" = "$dir" ]
|
||||||
|
assert [ "$type" = "tree" ]
|
||||||
echo $tree
|
echo $tree
|
||||||
break
|
break
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in a new issue