From c2489d09322aa1b89f36b21a55c94480afe7d584 Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Mon, 2 Nov 2015 17:07:05 -0800 Subject: [PATCH 01/11] update to the latest MSBuild scripts --- Octokit/Octokit-netcore45.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Octokit/Octokit-netcore45.csproj b/Octokit/Octokit-netcore45.csproj index 6f98071f..16f64286 100644 --- a/Octokit/Octokit-netcore45.csproj +++ b/Octokit/Octokit-netcore45.csproj @@ -410,7 +410,7 @@ CustomDictionary.xml - + - + \ No newline at end of file diff --git a/Octokit/Octokit-netcore45.csproj b/Octokit/Octokit-netcore45.csproj index e3a44809..44277e74 100644 --- a/Octokit/Octokit-netcore45.csproj +++ b/Octokit/Octokit-netcore45.csproj @@ -45,6 +45,7 @@ true ..\Octokit.ruleset bin\Release\NetCore45\Octokit.XML + 1591 diff --git a/Octokit/Octokit.csproj b/Octokit/Octokit.csproj index 3708c95b..bacb6546 100644 --- a/Octokit/Octokit.csproj +++ b/Octokit/Octokit.csproj @@ -41,6 +41,7 @@ true ..\Octokit.ruleset bin\Release\Net45\Octokit.XML + 1591 @@ -441,4 +442,4 @@ --> - + \ No newline at end of file From 50a2b97c1705b1c2956293ce62ccf8a60a46e32a Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Tue, 3 Nov 2015 09:31:33 -0800 Subject: [PATCH 08/11] actually some real errors --- Octokit/Clients/RepositoryContentsClient.cs | 4 ++++ Octokit/Models/Request/SearchRepositoriesRequest.cs | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Octokit/Clients/RepositoryContentsClient.cs b/Octokit/Clients/RepositoryContentsClient.cs index f23b10b4..6fc095a3 100644 --- a/Octokit/Clients/RepositoryContentsClient.cs +++ b/Octokit/Clients/RepositoryContentsClient.cs @@ -9,6 +9,10 @@ namespace Octokit /// public class RepositoryContentsClient : ApiClient, IRepositoryContentsClient { + /// + /// Create an instance of the RepositoryContentsClient + /// + /// The underlying connection to use public RepositoryContentsClient(IApiConnection apiConnection) : base(apiConnection) { } diff --git a/Octokit/Models/Request/SearchRepositoriesRequest.cs b/Octokit/Models/Request/SearchRepositoriesRequest.cs index 1aa5293e..36da4580 100644 --- a/Octokit/Models/Request/SearchRepositoriesRequest.cs +++ b/Octokit/Models/Request/SearchRepositoriesRequest.cs @@ -310,8 +310,6 @@ namespace Octokit /// /// Matches repositories with regards to both the and dates. /// - /// earlier date of the two - /// latter date of the two public DateRange(DateTime from, DateTime to) { query = string.Format(CultureInfo.InvariantCulture, "{0:yyyy-MM-dd}..{1:yyyy-MM-dd}", from, to); From bfb0559351b59cbd6444d17c4a0c448a5da0ff7d Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Mon, 2 Nov 2015 17:48:39 -0800 Subject: [PATCH 09/11] tidy up some xml-docs while i'm in here --- Octokit/Clients/IRepositoryContentsClient.cs | 10 ++++++++++ Octokit/Clients/OAuthClient.cs | 4 ++++ Octokit/Http/ApiResponse.cs | 19 +++++++++++++++++++ Octokit/Http/HttpVerb.cs | 4 ++-- Octokit/Http/ICredentialStore.cs | 7 +++++++ Octokit/Http/InMemoryCredentialStore.cs | 11 +++++++++++ Octokit/Models/Response/Meta.cs | 11 +++++++++++ README.md | 5 ----- 8 files changed, 64 insertions(+), 7 deletions(-) diff --git a/Octokit/Clients/IRepositoryContentsClient.cs b/Octokit/Clients/IRepositoryContentsClient.cs index d2923478..ba255103 100644 --- a/Octokit/Clients/IRepositoryContentsClient.cs +++ b/Octokit/Clients/IRepositoryContentsClient.cs @@ -167,11 +167,21 @@ namespace Octokit Task DeleteFile(string owner, string name, string path, DeleteFileRequest request); } + /// + /// The archive format to return from the server + /// public enum ArchiveFormat { + /// + /// The TAR archive format + /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Tarball")] [Parameter(Value = "tarball")] Tarball, + + /// + /// The ZIP archive format + /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Zipball")] [Parameter(Value = "zipball")] Zipball diff --git a/Octokit/Clients/OAuthClient.cs b/Octokit/Clients/OAuthClient.cs index 76499cc3..d283b5a4 100644 --- a/Octokit/Clients/OAuthClient.cs +++ b/Octokit/Clients/OAuthClient.cs @@ -12,6 +12,10 @@ namespace Octokit readonly IConnection connection; readonly Uri hostAddress; + /// + /// Create an instance of the OauthClient + /// + /// The underlying connection to use public OauthClient(IConnection connection) { Ensure.ArgumentNotNull(connection, "connection"); diff --git a/Octokit/Http/ApiResponse.cs b/Octokit/Http/ApiResponse.cs index 8b1c117c..d677af0c 100644 --- a/Octokit/Http/ApiResponse.cs +++ b/Octokit/Http/ApiResponse.cs @@ -1,11 +1,24 @@ namespace Octokit.Internal { + /// + /// Wrapper for a response from the API + /// + /// Payload contained in the response public class ApiResponse : IApiResponse { + /// + /// Create a ApiResponse from an existing request + /// + /// An existing request to wrap public ApiResponse(IResponse response) : this(response, GetBodyAsObject(response)) { } + /// + /// Create a ApiResponse from an existing request and object + /// + /// An existing request to wrap + /// The payload from an existing request public ApiResponse(IResponse response, T bodyAsObject) { Ensure.ArgumentNotNull(response, "response"); @@ -14,8 +27,14 @@ Body = bodyAsObject; } + /// + /// The payload of the response + /// public T Body { get; private set; } + /// + /// The context of the response + /// public IResponse HttpResponse { get; private set; } static T GetBodyAsObject(IResponse response) diff --git a/Octokit/Http/HttpVerb.cs b/Octokit/Http/HttpVerb.cs index 8454e65a..ad49fb78 100644 --- a/Octokit/Http/HttpVerb.cs +++ b/Octokit/Http/HttpVerb.cs @@ -2,11 +2,11 @@ namespace Octokit.Internal { - public static class HttpVerb + internal static class HttpVerb { static readonly HttpMethod patch = new HttpMethod("PATCH"); - public static HttpMethod Patch + internal static HttpMethod Patch { get { return patch; } } diff --git a/Octokit/Http/ICredentialStore.cs b/Octokit/Http/ICredentialStore.cs index d605678a..19e99b50 100644 --- a/Octokit/Http/ICredentialStore.cs +++ b/Octokit/Http/ICredentialStore.cs @@ -3,8 +3,15 @@ using System.Threading.Tasks; namespace Octokit { + /// + /// Abstraction for interacting with credentials + /// public interface ICredentialStore { + /// + /// Retrieve the credentials from the underlying store + /// + /// A continuation containing credentials [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification="Nope")] Task GetCredentials(); } diff --git a/Octokit/Http/InMemoryCredentialStore.cs b/Octokit/Http/InMemoryCredentialStore.cs index 33bce5d0..04ceec9e 100644 --- a/Octokit/Http/InMemoryCredentialStore.cs +++ b/Octokit/Http/InMemoryCredentialStore.cs @@ -2,10 +2,17 @@ namespace Octokit.Internal { + /// + /// Abstraction for interacting with credentials + /// public class InMemoryCredentialStore : ICredentialStore { readonly Credentials _credentials; + /// + /// Create an instance of the InMemoryCredentialStore + /// + /// public InMemoryCredentialStore(Credentials credentials) { Ensure.ArgumentNotNull(credentials, "credentials"); @@ -13,6 +20,10 @@ namespace Octokit.Internal _credentials = credentials; } + /// + /// Retrieve the credentials from the underlying store + /// + /// A continuation containing credentials public Task GetCredentials() { return Task.FromResult(_credentials); diff --git a/Octokit/Models/Response/Meta.cs b/Octokit/Models/Response/Meta.cs index 66720825..7c829bfa 100644 --- a/Octokit/Models/Response/Meta.cs +++ b/Octokit/Models/Response/Meta.cs @@ -11,10 +11,21 @@ namespace Octokit [DebuggerDisplay("{DebuggerDisplay,nq}")] public class Meta { + /// + /// Create an instance of the Meta + /// public Meta() { } + /// + /// Create an instance of the Meta + /// + /// Whether authentication with username and password is supported. + /// The currently-deployed SHA of github-services. + /// An array of IP addresses in CIDR format specifying the addresses that incoming service hooks will originate from on GitHub.com. + /// An array of IP addresses in CIDR format specifying the Git servers for the GitHub server + /// An array of IP addresses in CIDR format specifying the A records for GitHub Pages. public Meta( bool verifiablePasswordAuthentication, string gitHubServicesSha, diff --git a/README.md b/README.md index da695d96..c945222d 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,6 @@ ![logo](octokit-dotnet_2.png) - Octokit is a client library targeting .NET 4.5 and above that provides an easy way to interact with the [GitHub API](http://developer.github.com/v3/). @@ -64,10 +63,6 @@ cd Octokit Visit the [Contributor Guidelines](https://github.com/octokit/octokit.net/blob/master/CONTRIBUTING.md) for more details. -## Build Server - -The builds and tests for Octokit.net are run on [AppVeyor](http://www.appveyor.com). This enables us to build and test incoming pull requests: https://ci.appveyor.com/project/Haacked15676/octokit-net - ## Problems? Octokit is 100% certified to be bug free. If you find an issue with our From f468b526c6e901dce894689bedf4154bcd6cd199 Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Tue, 3 Nov 2015 13:02:28 -0800 Subject: [PATCH 10/11] one more malformed xml-docs tag --- Octokit/Models/Request/NewArbitraryMarkDown.cs | 1 - 1 file changed, 1 deletion(-) diff --git a/Octokit/Models/Request/NewArbitraryMarkDown.cs b/Octokit/Models/Request/NewArbitraryMarkDown.cs index a2993f9c..75e18f56 100644 --- a/Octokit/Models/Request/NewArbitraryMarkDown.cs +++ b/Octokit/Models/Request/NewArbitraryMarkDown.cs @@ -49,7 +49,6 @@ namespace Octokit /// /// The Markdown text to render /// The rendering mode. Can be either markdown by default or gfm - /// public NewArbitraryMarkdown(string text, string mode) : this(text, mode, null) { From ef906a81642c060a88736df1c9d602f7d81ce408 Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Tue, 3 Nov 2015 13:31:26 -0800 Subject: [PATCH 11/11] a bit more cleanup of the README --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c945222d..a990e371 100644 --- a/README.md +++ b/README.md @@ -46,10 +46,10 @@ Please see https://github.com/octokit/octokit.net/blob/master/docs/index.md for Octokit is a single assembly designed to be easy to deploy anywhere. If you prefer to compile it yourself, you’ll need: -* Visual Studio 2015, or Xamarin Studio +* Visual Studio 2015 or Xamarin Studio * Windows 8.1 or higher to build and test the WinRT projects -To clone it locally click the "Clone in Windows" button above or run the +To clone it locally click the "Clone in Desktop" button above or run the following git commands. ```