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

Change the target version to .net 4 and added support of .Net 4 #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
6 changes: 3 additions & 3 deletions Naos.WinRM/Naos.WinRM.cs
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ public static void RemoveIpAddressFromLocalTrustedHosts(string ipAddress)
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "Want a method due to amount of logic.")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Ip", Justification = "Name/spelling is correct.")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1709:IdentifiersShouldBeCasedCorrectly", MessageId = "Ip", Justification = "Name/spelling is correct.")]
public static IReadOnlyCollection<string> GetListOfIpAddressesFromLocalTrustedHosts()
public static IEnumerable<string> GetListOfIpAddressesFromLocalTrustedHosts()
{
lock (SyncTrustedHosts)
{
Expand Down Expand Up @@ -913,9 +913,9 @@ private List<dynamic> RunScriptUsingSession(
}
}

private static bool TrustedHostListIsWildCard(IReadOnlyCollection<string> trustedHostList)
private static bool TrustedHostListIsWildCard(IEnumerable<string> trustedHostList)
{
return trustedHostList.Count == 1 && trustedHostList.Single() == "*";
return trustedHostList.Count() == 1 && trustedHostList.Single() == "*";
}

private static List<PSObject> RunLocalCommand(Runspace runspace, Command arbitraryCommand)
Expand Down
6 changes: 3 additions & 3 deletions Naos.WinRM/Naos.WinRM.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Naos.WinRM</RootNamespace>
<AssemblyName>Naos.WinRM</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand Down Expand Up @@ -42,8 +43,7 @@
<Reference Include="System.Core" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Management.Automation, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Naos.External.MS-WinRM.1.0.0.1\lib\40\System.Management.Automation.dll</HintPath>
<Private>True</Private>
<HintPath>..\packages\Microsoft.PowerShell.5.ReferenceAssemblies.1.1.0\lib\net4\System.Management.Automation.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions Naos.WinRM/packages.config
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.PowerShell.5.ReferenceAssemblies" version="1.1.0" targetFramework="net40" />
<package id="Naos.Build.Analyzers" version="1.55.0" targetFramework="net45" developmentDependency="true" />
<package id="Naos.External.MS-WinRM" version="1.0.0.1" targetFramework="net45" />
<package id="StyleCop.Analyzers.Unstable" version="1.1.0.47" targetFramework="net45" developmentDependency="true" />
Expand Down