Port to .NET Core (#1503)

Port to .NET Core
This commit is contained in:
Mickaël Derriey
2017-01-21 15:42:02 +11:00
committed by Ryan Gribble
parent 3c818934b8
commit 13d5dab516
155 changed files with 1334 additions and 6014 deletions
+1 -9
View File
@@ -3,7 +3,6 @@ using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.Net;
using System.Reflection;
using System.Text;
using System.Text.RegularExpressions;
@@ -68,13 +67,6 @@ namespace Octokit
return new Uri(template);
}
#if NETFX_CORE
public static PropertyInfo GetProperty(this Type t, string propertyName)
{
return t.GetTypeInfo().GetDeclaredProperty(propertyName);
}
#endif
// :trollface:
[SuppressMessage("Microsoft.Globalization", "CA1308:NormalizeStringsToUppercase",
Justification = "Ruby don't care. Ruby don't play that.")]
@@ -123,7 +115,7 @@ namespace Octokit
// Username may only contain alphanumeric characters or single hyphens
// and cannot begin or end with a hyphen
static readonly Regex nameWithOwner = new Regex("[a-z0-9.-]{1,}/[a-z0-9.-_]{1,}",
#if (!PORTABLE && !NETFX_CORE)
#if HAS_REGEX_COMPILED_OPTIONS
RegexOptions.Compiled |
#endif
RegexOptions.IgnoreCase);