Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update LibGit2Sharp.NativeBinaries to 2.0.323 #2131

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from
Draft
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
8 changes: 4 additions & 4 deletions LibGit2Sharp.Tests/CloneFixture.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ public void CanClone(string url)
}

[Theory]
[InlineData("https://github.com/libgit2/TestGitRepository",1)]
[InlineData("https://github.com/libgit2/TestGitRepository",5)]
[InlineData("https://github.com/libgit2/TestGitRepository",7)]
[InlineData("https://github.com/libgit2/TestGitRepository", 1)]
[InlineData("https://github.com/libgit2/TestGitRepository", 5)]
[InlineData("https://github.com/libgit2/TestGitRepository", 7)]
public void CanCloneShallow(string url, int depth)
{
var scd = BuildSelfCleaningDirectory();
Expand Down Expand Up @@ -266,7 +266,7 @@ static Credentials CreateUsernamePasswordCredentials(string user, string pass, b

[SkippableTheory]
[InlineData("https://github.com/libgit2/TestGitRepository.git", "github.com", typeof(CertificateX509))]
[InlineData("git@github.com:libgit2/TestGitRepository.git", "github.com", typeof(CertificateSsh))]
//[InlineData("git@github.com:libgit2/TestGitRepository.git", "github.com", typeof(CertificateSsh))]
public void CanInspectCertificateOnClone(string url, string hostname, Type certType)
{
var scd = BuildSelfCleaningDirectory();
Expand Down
6 changes: 3 additions & 3 deletions LibGit2Sharp.Tests/GlobalSettingsFixture.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,17 +90,17 @@ public void SetExtensions()
var extensions = GlobalSettings.GetExtensions();

// Assert that "noop" is supported by default
Assert.Equal(new[] { "noop", "objectformat" }, extensions);
Assert.Equal(new[] { "noop", "objectformat", "worktreeconfig" }, extensions);

// Disable "noop" extensions
GlobalSettings.SetExtensions("!noop");
extensions = GlobalSettings.GetExtensions();
Assert.Equal(new[] { "objectformat" }, extensions);
Assert.Equal(new[] { "objectformat", "worktreeconfig" }, extensions);

// Enable two new extensions (it will reset the configuration and "noop" will be enabled)
GlobalSettings.SetExtensions("partialclone", "newext");
extensions = GlobalSettings.GetExtensions();
Assert.Equal(new[] { "newext", "noop", "objectformat", "partialclone" }, extensions);
Assert.Equal(new[] { "newext", "noop", "objectformat", "partialclone", "worktreeconfig" }, extensions);
}
}
}
5 changes: 5 additions & 0 deletions LibGit2Sharp/ConfigurationLevel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
/// </summary>
public enum ConfigurationLevel
{
/// <summary>
/// Worktree specific configuration file; $GIT_DIR/config.worktree
/// </summary>
Worktree = 6,

/// <summary>
/// The local .git/config of the current repository.
/// </summary>
Expand Down
4 changes: 2 additions & 2 deletions LibGit2Sharp/Core/GitConfigEntry.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
using System;
using System.Runtime.InteropServices;

namespace LibGit2Sharp.Core
Expand All @@ -8,9 +7,10 @@ internal unsafe struct GitConfigEntry
{
public char* namePtr;
public char* valuePtr;
public char* backend_type;
public char* origin_path;
public uint include_depth;
public uint level;
public void* freePtr;
public void* payloadPtr;
}
}
1 change: 1 addition & 0 deletions LibGit2Sharp/Core/GitPushOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ internal class GitPushOptions
public GitProxyOptions ProxyOptions;
public RemoteRedirectMode FollowRedirects = RemoteRedirectMode.Initial;
public GitStrArrayManaged CustomHeaders;
public GitStrArrayManaged remote_push_options;
}
}
4 changes: 2 additions & 2 deletions LibGit2Sharp/Core/GitWorktree.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Text;

namespace LibGit2Sharp.Core
{
Expand Down Expand Up @@ -36,6 +34,8 @@ internal class git_worktree_add_options

public int locked;

public int checkout_existing;

public IntPtr @ref = IntPtr.Zero;

public GitCheckoutOpts checkoutOpts = new GitCheckoutOpts { version = 1 };
Expand Down
2 changes: 1 addition & 1 deletion LibGit2Sharp/LibGit2Sharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="LibGit2Sharp.NativeBinaries" Version="[2.0.322]" PrivateAssets="none" />
<PackageReference Include="LibGit2Sharp.NativeBinaries" Version="[2.0.323]" PrivateAssets="none" />
<PackageReference Include="MinVer" Version="6.0.0" PrivateAssets="all" />
</ItemGroup>

Expand Down
16 changes: 7 additions & 9 deletions LibGit2Sharp/WorktreeCollection.cs
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
using LibGit2Sharp.Core;
using LibGit2Sharp.Core.Handles;
using System;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Text;
using LibGit2Sharp.Core;
using LibGit2Sharp.Core.Handles;

namespace LibGit2Sharp
{
Expand Down Expand Up @@ -48,7 +46,7 @@ public virtual Worktree this[string name]
}

/// <summary>
///
///
/// </summary>
/// <param name="committishOrBranchSpec"></param>
/// <param name="name"></param>
Expand Down Expand Up @@ -89,7 +87,7 @@ public virtual Worktree Add(string committishOrBranchSpec, string name, string p
}

/// <summary>
///
///
/// </summary>
/// <param name="name"></param>
/// <param name="path"></param>
Expand All @@ -112,7 +110,7 @@ public virtual Worktree Add(string name, string path, bool isLocked)
}

/// <summary>
///
///
/// </summary>
/// <param name="worktree"></param>
/// <returns></returns>
Expand All @@ -122,7 +120,7 @@ public virtual bool Prune(Worktree worktree)
}

/// <summary>
///
///
/// </summary>
/// <param name="worktree"></param>
/// <param name="ifLocked"></param>
Expand Down