|
1 | 1 | <Project Sdk="Microsoft.NET.Sdk"> |
2 | 2 |
|
3 | 3 | <PropertyGroup> |
4 | | - <TargetFramework>netcoreapp2.1</TargetFramework> |
| 4 | + <TargetFramework>netstandard2.0</TargetFramework> |
5 | 5 | <GenerateAssemblyInfo>true</GenerateAssemblyInfo> |
6 | 6 | <GenerateDocumentationFile>true</GenerateDocumentationFile> |
7 | 7 | <PublishTrimmed>true</PublishTrimmed> |
|
43 | 43 | DestinationFolder="$(OutputPath)" /> |
44 | 44 | <Exec Command='pwsh -noni -nop -c "cd ..\..; Invoke-Pester"' |
45 | 45 | IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" /> |
| 46 | + <Exec Command='powershell -noni -nop -c "cd ..\..; Invoke-Pester"' |
| 47 | + IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" /> |
46 | 48 | </Target> |
47 | 49 |
|
48 | 50 | <ItemGroup> |
49 | 51 | <PSModulePath Include="$(PSModulePath)" Exclude="C:\Program Files\**;C:\Windows\**;C:\ProgramData\chocolatey\**" /> |
50 | 52 | </ItemGroup> |
51 | 53 |
|
52 | | - <Target Name="PublishModule" DependsOnTargets="Publish" Condition="'$(Configuration)' == 'Release'"> |
53 | | - <RemoveDir Directories="@(PSModulePath->'%(FullPath)\$(MSBuildProjectName)')" /> |
54 | | - <Copy SourceFiles="$(OutputPath)\publish\FSharp.Core.dll" DestinationFolder="$(OutputPath)" /> |
55 | | - <ItemGroup><ModuleFiles Include="$(OutputPath)\*" /></ItemGroup> |
56 | | - <Copy SourceFiles="@(ModuleFiles)" DestinationFolder="@(PSModulePath->'%(FullPath)\$(MSBuildProjectName)\$(Version)')" /> |
57 | | - <Exec Command='pwsh -noni -nop -c "[bool](Get-SecretInfo $(MSBuildProjectName) -Vault PowerShellGallery)"' |
58 | | - ConsoleToMSBuild="true" IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true"> |
59 | | - <Output TaskParameter="ConsoleOutput" PropertyName="HasApiKey" /> |
60 | | - </Exec> |
61 | | - <Error Text="To publish, first run: .\Set-ApiKey.ps1" Condition="!$(HasApiKey)" /> |
62 | | - <Exec Command='pwsh -nop -c "(New-Object PSCredential _,(Get-Secret $(MSBuildProjectName) -Vault PowerShellGallery)).GetNetworkCredential().Password"' |
63 | | - ConsoleToMSBuild="true" IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" Condition="$(HasApiKey)"> |
64 | | - <Output TaskParameter="ConsoleOutput" PropertyName="ApiKey" /> |
65 | | - </Exec> |
66 | | - <Exec Command='pwsh -noni -nop -c "Import-Module $(MSBuildProjectName); Publish-Module -Name $(MSBuildProjectName) -NuGetApiKey $(ApiKey)"' |
67 | | - IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" Condition="$(HasApiKey)" /> |
68 | | - </Target> |
69 | | - |
70 | 54 | </Project> |
0 commit comments