libgit2 / libgit2/libgit2sharp
LibGit2SharpException: unknown style 'zdiff3' given for 'merge.conflictstyle'
Open
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 3.5k
- Forks
- 925
- PR merge metrics
- No merged PRs in 30d
Description
Reproduction steps
set in gitconfig merge.conflictstyle to zdiff3
Expected behavior
Working libgit2sharp
Actual behavior
LibGit2Sharp.LibGit2SharpException: unknown style 'zdiff3' given for 'merge.conflictstyle'
at LibGit2Sharp.Core.Ensure.HandleError(Int32 result)
at LibGit2Sharp.Core.Ensure.ZeroResult(Int32 result)
at LibGit2Sharp.Core.Proxy.git_checkout_tree(RepositoryHandle repo, ObjectId treeId, GitCheckoutOpts& opts)
at LibGit2Sharp.Repository.CheckoutTree(Tree tree, IList`1 paths, IConvertableToGitCheckoutOpts opts)
at LibGit2Sharp.Repository.Checkout(Tree tree, IEnumerable`1 paths, CheckoutOptions options)
at LibGit2Sharp.Commands.Checkout(IRepository repository, Tree tree, CheckoutOptions checkoutOptions, String refLogHeadSpec)
at LibGit2Sharp.Commands.Checkout(IRepository repository, Branch branch, CheckoutOptions options)
at LibGit2Sharp.Commands.Checkout(IRepository repository, Branch branch)
at Nerdbank.GitVersioning.ReleaseManager.PrepareRelease(String projectDirectory, String releaseUnstableTag, Version nextVersion, Nullable`1 versionIncrement, ReleaseManagerOutputMode outputMode) in D:\a\1\s\src\NerdBank.GitVersioning\ReleaseManager.cs:line 285
at Nerdbank.GitVersioning.Tool.Program.OnPrepareReleaseCommand(String project, String nextVersion, String versionIncrement, String format, String tag) in D:\a\1\s\src\nbgv\Program.cs:line 736
--- End of inner exception stack trace ---
Version of LibGit2Sharp (release number or SHA1)
0.27.0-preview-0182
Operating system(s) tested; .NET runtime tested
Windows / dotnet 6.0.5
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the reported Repository.Checkout, Commands.Checkout, and Core.Proxy.git_checkout_tree calls to where merge.conflictstyle is handled. Confirm the behavior with merge.conflictstyle set to zdiff3 on the stated Windows/.NET environment, then add or update coverage so checkout no longer fails for that setting.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, git
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100