Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion GVFS/GVFS.Common/Git/GitProcess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ public Result MultiPackIndexRepack(string gitObjectDirectory, string batchSize)

public Result GetHeadTreeId()
{
return this.InvokeGitAgainstDotGitFolder("show -s --format=%T HEAD", usePreCommandHook: false);
return this.InvokeGitAgainstDotGitFolder("rev-parse \"HEAD^{tree}\"", usePreCommandHook: false);
}

public Process GetGitProcess(string command, string workingDirectory, string dotGitDirectory, bool useReadObjectHook, bool redirectStandardError, string gitObjectsDirectory, bool usePreCommandHook)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ public void HeadTreeCountCacheTests((string CachePrecontents, string ExpectedCac
this.enlistmentDirectory.CreateFile(totalPathCountPath, args.CachePrecontents, createDirectories: true);
}

this.gitProcess.SetExpectedCommandResult("show -s --format=%T HEAD",
this.gitProcess.SetExpectedCommandResult("rev-parse \"HEAD^{tree}\"",
() => new GitProcess.Result(HeadTreeId, "", 0));
this.gitProcess.SetExpectedCommandResult("ls-tree -r -d HEAD",
() => new GitProcess.Result(
Expand Down
Loading