From 36948246bd3b3594930fb4f68139c7cdbed00953 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:21:10 +0000 Subject: [PATCH 1/9] Update Paket, FCS, and .NET Core --- .paket/Paket.Restore.targets | 89 +++++++++++++----------- paket.dependencies | 12 ++-- paket.lock | 40 +++++------ src/IfSharp/IfSharp.fsproj | 3 + src/IfSharpNetCore/IfSharpNetCore.fsproj | 2 +- 5 files changed, 78 insertions(+), 68 deletions(-) diff --git a/.paket/Paket.Restore.targets b/.paket/Paket.Restore.targets index a795558..dfc4aae 100644 --- a/.paket/Paket.Restore.targets +++ b/.paket/Paket.Restore.targets @@ -20,7 +20,7 @@ proj assembly native - /Library/Frameworks/Mono.framework/Commands/mono + /Library/Frameworks/Mono.framework/Commands/mono mono @@ -28,67 +28,74 @@ $(PaketToolsPath)paket.bootstrapper.exe $([System.IO.Path]::GetDirectoryName("$(PaketBootStrapperExePath)"))\ - "$(PaketBootStrapperExePath)" + "$(PaketBootStrapperExePath)" $(MonoPath) --runtime=v4.0.30319 "$(PaketBootStrapperExePath)" - - - - true - true - True + + False + $(BaseIntermediateOutputPath.TrimEnd('\').TrimEnd('\/')) - + + - - - - - + + + + $(PaketRootPath)paket + $(PaketToolsPath)paket + - - - dotnet paket + + + + $(PaketRootPath)paket.exe + $(PaketToolsPath)paket.exe - - - - $(PaketRootPath)paket.exe - $(PaketToolsPath)paket.exe - $(PaketToolsPath)paket.exe - $(_PaketBootStrapperExeDir)paket.exe - paket.exe + + + + <_DotnetToolsJson Condition="Exists('$(PaketRootPath)/.config/dotnet-tools.json')">$([System.IO.File]::ReadAllText("$(PaketRootPath)/.config/dotnet-tools.json")) + <_ConfigContainsPaket Condition=" '$(_DotnetToolsJson)' != ''">$(_DotnetToolsJson.Contains('"paket"')) + <_ConfigContainsPaket Condition=" '$(_ConfigContainsPaket)' == ''">false + - - $(PaketRootPath)paket - $(PaketToolsPath)paket - $(PaketToolsPath)paket + + + + + - - $(PaketRootPath)paket.exe - $(PaketToolsPath)paket.exe + + + <_PaketCommand>dotnet paket + - - $(PaketBootStrapperExeDir)paket.exe + + + + $(PaketToolsPath)paket + $(PaketBootStrapperExeDir)paket - - paket + + paket + + + <_PaketExeExtension>$([System.IO.Path]::GetExtension("$(PaketExePath)")) - dotnet "$(PaketExePath)" - $(MonoPath) --runtime=v4.0.30319 "$(PaketExePath)" - "$(PaketExePath)" - + <_PaketCommand Condition=" '$(_PaketCommand)' == '' AND '$(_PaketExeExtension)' == '.dll' ">dotnet "$(PaketExePath)" + <_PaketCommand Condition=" '$(_PaketCommand)' == '' AND '$(OS)' != 'Windows_NT' AND '$(_PaketExeExtension)' == '.exe' ">$(MonoPath) --runtime=v4.0.30319 "$(PaketExePath)" + <_PaketCommand Condition=" '$(_PaketCommand)' == '' ">"$(PaketExePath)" - + diff --git a/paket.dependencies b/paket.dependencies index 096d55b..d26e1fd 100644 --- a/paket.dependencies +++ b/paket.dependencies @@ -1,32 +1,32 @@ -version 5.231.2 +version 5.241.5 framework: net472 source https://api.nuget.org/v3/index.json -nuget FSharp.Compiler.Service ~> 33.0.0 +nuget FSharp.Compiler.Service ~> 33.0.1 nuget FSharp.Compiler.Tools ~> 10.2.3 nuget FSharp.Core = 4.7.0 nuget AsyncIO >= 0.1.69 nuget NetMQ ~> 4.0.0.239-pre nuget Newtonsoft.Json ~> 12.0.3 nuget FAKE >= 5.16.0 -nuget Paket.Core ~> 5.231.2 +nuget Paket.Core ~> 5.241.5 nuget Trinet.Core.IO.Ntfs nuget system.memory 4.5.3 group NETCORE -framework: netstandard2.0, netcoreapp2.2 +framework: netstandard2.0, netcoreapp3.1 source https://api.nuget.org/v3/index.json -nuget FSharp.Compiler.Service ~> 33.0.0 +nuget FSharp.Compiler.Service ~> 33.0.1 nuget FSharp.Compiler.Tools ~> 10.2.3 nuget FSharp.Core = 4.7.0 nuget AsyncIO >= 0.1.69 nuget NetMQ ~> 4.0.0.239-pre nuget Newtonsoft.Json ~> 12.0.3 nuget FAKE >= 5.16.0 -nuget Paket.Core ~> 5.231.2 +nuget Paket.Core ~> 5.241.5 nuget Trinet.Core.IO.Ntfs nuget system.memory 4.5.3 diff --git a/paket.lock b/paket.lock index 2f8dc3c..25dc447 100644 --- a/paket.lock +++ b/paket.lock @@ -6,7 +6,7 @@ NUGET FSharp.Core (>= 4.0.1.7-alpha) NETStandard.Library (>= 1.6) FAKE (5.16) - FSharp.Compiler.Service (33.0) + FSharp.Compiler.Service (33.0.1) FSharp.Core (>= 4.6.2) System.Collections.Immutable (>= 1.5) System.Reflection.Metadata (>= 1.6) @@ -20,7 +20,7 @@ NUGET NETStandard.Library (2.0.3) Microsoft.NETCore.Platforms (>= 1.1) Newtonsoft.Json (12.0.3) - Paket.Core (5.231.2) + Paket.Core (5.241.5) Chessie (>= 0.6) FSharp.Compiler.Tools FSharp.Core (> 4.3) @@ -801,7 +801,7 @@ NUGET System.Xml.XPath (>= 4.3) - restriction: || (&& (< monoandroid) (< monotouch) (>= netstandard1.3) (< xamarinios) (< xamarinmac) (< xamarintvos) (< xamarinwatchos)) (>= net46) GROUP NETCORE -RESTRICTION: || (== netcoreapp2.2) (== netstandard2.0) +RESTRICTION: || (== netcoreapp3.1) (== netstandard2.0) NUGET remote: https://api.nuget.org/v3/index.json AsyncIO (0.1.69) @@ -809,7 +809,7 @@ NUGET FSharp.Core (>= 4.0.1.7-alpha) NETStandard.Library (>= 1.6) FAKE (5.16) - FSharp.Compiler.Service (33.0) + FSharp.Compiler.Service (33.0.1) FSharp.Core (>= 4.6.2) System.Collections.Immutable (>= 1.5) System.Diagnostics.Process (>= 4.1) @@ -828,8 +828,8 @@ NUGET Microsoft.NETCore.Targets (>= 1.1) System.Runtime (>= 4.3) Microsoft.Win32.Registry (4.5) - System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp2.2) (>= monoandroid) (< netstandard2.0)) (&& (== netcoreapp2.2) (>= monotouch)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (>= xamarinios)) (&& (== netcoreapp2.2) (>= xamarinmac)) (&& (== netcoreapp2.2) (>= xamarintvos)) (&& (== netcoreapp2.2) (>= xamarinwatchos)) (== netstandard2.0) - System.Memory (>= 4.5) - restriction: || (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netcoreapp2.1)) (&& (== netcoreapp2.2) (>= uap10.1)) (== netstandard2.0) + System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp3.1) (>= monoandroid) (< netstandard2.0)) (&& (== netcoreapp3.1) (>= monotouch)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (>= xamarinios)) (&& (== netcoreapp3.1) (>= xamarinmac)) (&& (== netcoreapp3.1) (>= xamarintvos)) (&& (== netcoreapp3.1) (>= xamarinwatchos)) (== netstandard2.0) + System.Memory (>= 4.5) - restriction: || (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netcoreapp2.1)) (&& (== netcoreapp3.1) (>= uap10.1)) (== netstandard2.0) System.Security.AccessControl (>= 4.5) System.Security.Principal.Windows (>= 4.5) Mono.Cecil (0.10.3) @@ -841,14 +841,14 @@ NUGET System.Security.Cryptography.Algorithms (>= 4.2) System.Security.Cryptography.Csp (>= 4.0) System.Threading (>= 4.0.11) - NetMQ (4.0.0.239-pre) + NetMQ (4.0.0.272-pre) AsyncIO (>= 0.1.69) System.ServiceModel.Primitives (>= 4.4) System.ValueTuple (>= 4.4) NETStandard.Library (2.0.3) Microsoft.NETCore.Platforms (>= 1.1) Newtonsoft.Json (12.0.3) - Paket.Core (5.231.2) + Paket.Core (5.241.5) Chessie (>= 0.6) Mono.Cecil (>= 0.10.0-beta6) Newtonsoft.Json (>= 10.0.3) @@ -891,7 +891,7 @@ NUGET runtime.ubuntu.16.04-x64.runtime.native.System.Security.Cryptography.OpenSsl (4.3.3) runtime.ubuntu.16.10-x64.runtime.native.System.Security.Cryptography.OpenSsl (4.3.3) runtime.ubuntu.18.04-x64.runtime.native.System.Security.Cryptography.OpenSsl (4.3.3) - System.Buffers (4.5) - restriction: || (&& (== netcoreapp2.2) (>= monotouch)) (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netstandard1.1)) (&& (== netcoreapp2.2) (< netstandard2.0)) (&& (== netcoreapp2.2) (>= xamarinios)) (&& (== netcoreapp2.2) (>= xamarinmac)) (&& (== netcoreapp2.2) (>= xamarintvos)) (&& (== netcoreapp2.2) (>= xamarinwatchos)) (== netstandard2.0) + System.Buffers (4.5) - restriction: || (&& (== netcoreapp3.1) (>= monotouch)) (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netstandard1.1)) (&& (== netcoreapp3.1) (< netstandard2.0)) (&& (== netcoreapp3.1) (>= xamarinios)) (&& (== netcoreapp3.1) (>= xamarinmac)) (&& (== netcoreapp3.1) (>= xamarintvos)) (&& (== netcoreapp3.1) (>= xamarinwatchos)) (== netstandard2.0) System.Collections (4.3) Microsoft.NETCore.Platforms (>= 1.1) Microsoft.NETCore.Targets (>= 1.1) @@ -976,13 +976,13 @@ NUGET System.Runtime (>= 4.3) System.Runtime.Extensions (>= 4.3) System.Memory (4.5.3) - System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp2.2) (>= monotouch)) (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netstandard1.1)) (&& (== netcoreapp2.2) (< netstandard2.0)) (&& (== netcoreapp2.2) (>= xamarinios)) (&& (== netcoreapp2.2) (>= xamarinmac)) (&& (== netcoreapp2.2) (>= xamarintvos)) (&& (== netcoreapp2.2) (>= xamarinwatchos)) (== netstandard2.0) - System.Numerics.Vectors (>= 4.4) - restriction: || (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (== netstandard2.0) - System.Runtime.CompilerServices.Unsafe (>= 4.5.2) - restriction: || (&& (== netcoreapp2.2) (>= monotouch)) (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netcoreapp2.1)) (&& (== netcoreapp2.2) (< netstandard1.1)) (&& (== netcoreapp2.2) (< netstandard2.0)) (&& (== netcoreapp2.2) (>= uap10.1)) (&& (== netcoreapp2.2) (>= xamarinios)) (&& (== netcoreapp2.2) (>= xamarinmac)) (&& (== netcoreapp2.2) (>= xamarintvos)) (&& (== netcoreapp2.2) (>= xamarinwatchos)) (== netstandard2.0) + System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp3.1) (>= monotouch)) (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netstandard1.1)) (&& (== netcoreapp3.1) (< netstandard2.0)) (&& (== netcoreapp3.1) (>= xamarinios)) (&& (== netcoreapp3.1) (>= xamarinmac)) (&& (== netcoreapp3.1) (>= xamarintvos)) (&& (== netcoreapp3.1) (>= xamarinwatchos)) (== netstandard2.0) + System.Numerics.Vectors (>= 4.4) - restriction: || (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (== netstandard2.0) + System.Runtime.CompilerServices.Unsafe (>= 4.5.2) - restriction: || (&& (== netcoreapp3.1) (>= monotouch)) (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netcoreapp2.1)) (&& (== netcoreapp3.1) (< netstandard1.1)) (&& (== netcoreapp3.1) (< netstandard2.0)) (&& (== netcoreapp3.1) (>= uap10.1)) (&& (== netcoreapp3.1) (>= xamarinios)) (&& (== netcoreapp3.1) (>= xamarinmac)) (&& (== netcoreapp3.1) (>= xamarintvos)) (&& (== netcoreapp3.1) (>= xamarinwatchos)) (== netstandard2.0) System.Net.Http.WinHttpHandler (4.5.2) - System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp2.2) (< netcoreapp2.0)) (== netstandard2.0) - System.Memory (>= 4.5.1) - restriction: || (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netcoreapp2.1)) (&& (== netcoreapp2.2) (>= uap10.1)) (== netstandard2.0) - System.Numerics.Vectors (4.5) - restriction: || (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (== netstandard2.0) + System.Buffers (>= 4.4) - restriction: || (&& (== netcoreapp3.1) (< netcoreapp2.0)) (== netstandard2.0) + System.Memory (>= 4.5.1) - restriction: || (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netcoreapp2.1)) (&& (== netcoreapp3.1) (>= uap10.1)) (== netstandard2.0) + System.Numerics.Vectors (4.5) - restriction: || (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (== netstandard2.0) System.Private.ServiceModel (4.5.3) Microsoft.NETCore.Platforms (>= 2.1) System.Reflection.DispatchProxy (>= 4.5) @@ -1005,7 +1005,7 @@ NUGET System.Reflection.Primitives (>= 4.3) System.Runtime (>= 4.3) System.Reflection.Metadata (1.6) - System.Collections.Immutable (>= 1.5) - restriction: || (&& (== netcoreapp2.2) (>= net45)) (&& (== netcoreapp2.2) (< netcoreapp2.1)) (&& (== netcoreapp2.2) (< netstandard1.1)) (&& (== netcoreapp2.2) (< netstandard2.0)) (== netstandard2.0) + System.Collections.Immutable (>= 1.5) - restriction: || (&& (== netcoreapp3.1) (>= net45)) (&& (== netcoreapp3.1) (< netcoreapp2.1)) (&& (== netcoreapp3.1) (< netstandard1.1)) (&& (== netcoreapp3.1) (< netstandard2.0)) (== netstandard2.0) System.Reflection.Primitives (4.3) Microsoft.NETCore.Platforms (>= 1.1) Microsoft.NETCore.Targets (>= 1.1) @@ -1020,7 +1020,7 @@ NUGET System.Runtime (4.3.1) Microsoft.NETCore.Platforms (>= 1.1.1) Microsoft.NETCore.Targets (>= 1.1.3) - System.Runtime.CompilerServices.Unsafe (4.5.2) - restriction: || (&& (== netcoreapp2.2) (>= monotouch)) (&& (== netcoreapp2.2) (>= net461)) (&& (== netcoreapp2.2) (< netcoreapp2.0)) (&& (== netcoreapp2.2) (< netcoreapp2.1)) (&& (== netcoreapp2.2) (< netstandard1.1)) (&& (== netcoreapp2.2) (< netstandard2.0)) (&& (== netcoreapp2.2) (>= uap10.1)) (&& (== netcoreapp2.2) (>= xamarinios)) (&& (== netcoreapp2.2) (>= xamarinmac)) (&& (== netcoreapp2.2) (>= xamarintvos)) (&& (== netcoreapp2.2) (>= xamarinwatchos)) (== netstandard2.0) + System.Runtime.CompilerServices.Unsafe (4.7) - restriction: || (&& (== netcoreapp3.1) (>= monotouch)) (&& (== netcoreapp3.1) (>= net461)) (&& (== netcoreapp3.1) (< netcoreapp2.0)) (&& (== netcoreapp3.1) (< netcoreapp2.1)) (&& (== netcoreapp3.1) (< netstandard1.1)) (&& (== netcoreapp3.1) (< netstandard2.0)) (&& (== netcoreapp3.1) (>= uap10.1)) (&& (== netcoreapp3.1) (>= xamarinios)) (&& (== netcoreapp3.1) (>= xamarinmac)) (&& (== netcoreapp3.1) (>= xamarintvos)) (&& (== netcoreapp3.1) (>= xamarinwatchos)) (== netstandard2.0) System.Runtime.Extensions (4.3.1) Microsoft.NETCore.Platforms (>= 1.1.1) Microsoft.NETCore.Targets (>= 1.1.3) @@ -1046,7 +1046,7 @@ NUGET System.Runtime (>= 4.3) System.Runtime.Extensions (>= 4.3) System.Security.AccessControl (4.5) - Microsoft.NETCore.Platforms (>= 2.0) - restriction: || (== netcoreapp2.2) (&& (== netstandard2.0) (>= netcoreapp2.0)) + Microsoft.NETCore.Platforms (>= 2.0) - restriction: || (== netcoreapp3.1) (&& (== netstandard2.0) (>= netcoreapp2.0)) System.Security.Principal.Windows (>= 4.5) System.Security.Cryptography.Algorithms (4.3.1) Microsoft.NETCore.Platforms (>= 1.1) @@ -1099,9 +1099,9 @@ NUGET System.Threading (>= 4.3) System.Threading.Tasks (>= 4.3) System.Security.Cryptography.ProtectedData (4.5) - System.Memory (>= 4.5) - restriction: || (&& (== netcoreapp2.2) (< netcoreapp2.1)) (== netstandard2.0) + System.Memory (>= 4.5) - restriction: || (&& (== netcoreapp3.1) (< netcoreapp2.1)) (== netstandard2.0) System.Security.Principal.Windows (4.5.1) - Microsoft.NETCore.Platforms (>= 2.0) - restriction: || (== netcoreapp2.2) (&& (== netstandard2.0) (>= netcoreapp2.0)) + Microsoft.NETCore.Platforms (>= 2.0) - restriction: || (== netcoreapp3.1) (&& (== netstandard2.0) (>= netcoreapp2.0)) System.ServiceModel.Primitives (4.5.3) System.Private.ServiceModel (>= 4.5.3) System.Text.Encoding (4.3) diff --git a/src/IfSharp/IfSharp.fsproj b/src/IfSharp/IfSharp.fsproj index 71db050..1ec8af7 100644 --- a/src/IfSharp/IfSharp.fsproj +++ b/src/IfSharp/IfSharp.fsproj @@ -182,6 +182,9 @@ + + True + ..\..\packages\FSharp.Compiler.Service\lib\net461\FSharp.Compiler.Service.dll True diff --git a/src/IfSharpNetCore/IfSharpNetCore.fsproj b/src/IfSharpNetCore/IfSharpNetCore.fsproj index ed3c6e5..4794ab6 100644 --- a/src/IfSharpNetCore/IfSharpNetCore.fsproj +++ b/src/IfSharpNetCore/IfSharpNetCore.fsproj @@ -2,7 +2,7 @@ Exe - netcoreapp2.2 + netcoreapp3.1 x64 x64 true From 46857570c487983ce8398365968390ae39208554 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:27:10 +0000 Subject: [PATCH 2/9] Update pipeline for .NET Core 3.1 --- azure-pipelines.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index cf06da9..ee34078 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -11,19 +11,23 @@ jobs: pool: vmImage: 'windows-2019' steps: + - task: UseDotNet@2 + inputs: + version: 3.1.100 - script: fake.cmd build --target All - job: macOS pool: vmImage: 'macOS-10.14' steps: + - task: UseDotNet@2 + inputs: + version: 3.1.100 - bash: . '$(Build.SourcesDirectory)/fake.sh' build --target BuildNetCore - job: Linux pool: vmImage: 'ubuntu-18.04' steps: - - bash: . '$(Build.SourcesDirectory)/fake.sh' build --target BuildNetCore - -#- script: | -# echo Add other tasks to build, test, and deploy your project. -# echo See https://aka.ms/yaml -# displayName: 'Run a multi-line script' + - task: UseDotNet@2 + inputs: + version: 3.1.100 + - bash: . '$(Build.SourcesDirectory)/fake.sh' build --target BuildNetCore \ No newline at end of file From 56b192d53f151ae5cd55f6dfd2dd0cbabc3d2484 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:44:05 +0000 Subject: [PATCH 3/9] Try using .NET local tools https://stu.dev/dotnet-core-3-local-tools/ --- .config/dotnet-tools.json | 12 ++++++++++++ azure-pipelines.yml | 6 +++--- fake.cmd | 9 ++------- fake.sh | 27 ++------------------------- 4 files changed, 19 insertions(+), 35 deletions(-) create mode 100644 .config/dotnet-tools.json diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json new file mode 100644 index 0000000..1688cba --- /dev/null +++ b/.config/dotnet-tools.json @@ -0,0 +1,12 @@ +{ + "version": 1, + "isRoot": true, + "tools": { + "fake-cli": { + "version": "5.19.0", + "commands": [ + "fake" + ] + } + } +} \ No newline at end of file diff --git a/azure-pipelines.yml b/azure-pipelines.yml index ee34078..5eacded 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -14,7 +14,7 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - script: fake.cmd build --target All + - script: dotnet fake build --target All - job: macOS pool: vmImage: 'macOS-10.14' @@ -22,7 +22,7 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: . '$(Build.SourcesDirectory)/fake.sh' build --target BuildNetCore + - bash: dotnet fake build --target BuildNetCore - job: Linux pool: vmImage: 'ubuntu-18.04' @@ -30,4 +30,4 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: . '$(Build.SourcesDirectory)/fake.sh' build --target BuildNetCore \ No newline at end of file + - bash: dotnet fake build --target BuildNetCore \ No newline at end of file diff --git a/fake.cmd b/fake.cmd index 2f757d1..43536ae 100644 --- a/fake.cmd +++ b/fake.cmd @@ -1,7 +1,2 @@ -SET TOOL_PATH=.fake - -IF NOT EXIST "%TOOL_PATH%\fake.exe" ( - dotnet tool install fake-cli --tool-path ./%TOOL_PATH% -) - -"%TOOL_PATH%/fake.exe" %* \ No newline at end of file +dotnet tool restore +dotnet fake %* \ No newline at end of file diff --git a/fake.sh b/fake.sh index e73ba16..bc92bc9 100644 --- a/fake.sh +++ b/fake.sh @@ -3,28 +3,5 @@ set -eu set -o pipefail -# workaround macOS build agent issue from https://github.com/dotnet/cli/issues/9114#issuecomment-494226139 -export DOTNET_ROOT="$(dirname "$(readlink "$(command -v dotnet)")")" - -# liberated from https://stackoverflow.com/a/18443300/433393 -realpath() { - OURPWD=$PWD - cd "$(dirname "$1")" - LINK=$(readlink "$(basename "$1")") - while [ "$LINK" ]; do - cd "$(dirname "$LINK")" - LINK=$(readlink "$(basename "$1")") - done - REALPATH="$PWD/$(basename "$1")" - cd "$OURPWD" - echo "$REALPATH" -} - -TOOL_PATH=$(realpath .fake) -FAKE="$TOOL_PATH"/fake - -if ! [ -e "$FAKE" ] -then - dotnet tool install fake-cli --tool-path "$TOOL_PATH" -fi -"$FAKE" "$@" +dotnet tool restore +dotnet fake "$@" \ No newline at end of file From d77de4c340e2f31c7f72949669476dc1e336403e Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:45:49 +0000 Subject: [PATCH 4/9] Tool restore first --- azure-pipelines.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 5eacded..2df46be 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -14,7 +14,9 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - script: dotnet fake build --target All + - script: + dotnet tool restore + dotnet fake build --target All - job: macOS pool: vmImage: 'macOS-10.14' @@ -22,7 +24,9 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: dotnet fake build --target BuildNetCore + - bash: + dotnet tool restore + dotnet fake build --target BuildNetCore - job: Linux pool: vmImage: 'ubuntu-18.04' @@ -30,4 +34,6 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: dotnet fake build --target BuildNetCore \ No newline at end of file + - bash: + dotnet tool restore + dotnet fake build --target BuildNetCore \ No newline at end of file From aca0a1a31bd1a795ba8ae6d5ec304cc7a74bfde2 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:48:13 +0000 Subject: [PATCH 5/9] Multiline script --- azure-pipelines.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 2df46be..80b5399 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -14,7 +14,7 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - script: + - script: | dotnet tool restore dotnet fake build --target All - job: macOS @@ -24,7 +24,7 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: + - bash: | dotnet tool restore dotnet fake build --target BuildNetCore - job: Linux @@ -34,6 +34,6 @@ jobs: - task: UseDotNet@2 inputs: version: 3.1.100 - - bash: + - bash: | dotnet tool restore dotnet fake build --target BuildNetCore \ No newline at end of file From 099c665414fca781c569d423b347a5894e509017 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:51:44 +0000 Subject: [PATCH 6/9] Fixing multiline... --- azure-pipelines.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 80b5399..4c2d3dd 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -15,8 +15,8 @@ jobs: inputs: version: 3.1.100 - script: | - dotnet tool restore - dotnet fake build --target All + dotnet tool restore + dotnet fake build --target All - job: macOS pool: vmImage: 'macOS-10.14' @@ -25,8 +25,8 @@ jobs: inputs: version: 3.1.100 - bash: | - dotnet tool restore - dotnet fake build --target BuildNetCore + dotnet tool restore + dotnet fake build --target BuildNetCore - job: Linux pool: vmImage: 'ubuntu-18.04' @@ -35,5 +35,5 @@ jobs: inputs: version: 3.1.100 - bash: | - dotnet tool restore - dotnet fake build --target BuildNetCore \ No newline at end of file + dotnet tool restore + dotnet fake build --target BuildNetCore \ No newline at end of file From 97ea2410077f9c7d94decbb1eda360751711e4bc Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 09:55:07 +0000 Subject: [PATCH 7/9] Fighting YAML multiple line syntax --- azure-pipelines.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 4c2d3dd..9294ab8 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -15,8 +15,8 @@ jobs: inputs: version: 3.1.100 - script: | - dotnet tool restore - dotnet fake build --target All + dotnet tool restore + dotnet fake build --target All - job: macOS pool: vmImage: 'macOS-10.14' @@ -25,8 +25,8 @@ jobs: inputs: version: 3.1.100 - bash: | - dotnet tool restore - dotnet fake build --target BuildNetCore + dotnet tool restore + dotnet fake build --target BuildNetCore - job: Linux pool: vmImage: 'ubuntu-18.04' @@ -35,5 +35,5 @@ jobs: inputs: version: 3.1.100 - bash: | - dotnet tool restore - dotnet fake build --target BuildNetCore \ No newline at end of file + dotnet tool restore + dotnet fake build --target BuildNetCore \ No newline at end of file From 63394d24cf037682e7a30ab0e2025cbc2c02bda4 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 10:27:17 +0000 Subject: [PATCH 8/9] Tool restore for Travis as well --- build.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/build.sh b/build.sh index 393b244..327a6ff 100755 --- a/build.sh +++ b/build.sh @@ -1,2 +1,3 @@ #!/usr/bin/env bash +dotnet tool restore source fake.sh build "$@" \ No newline at end of file From 16e7785cd1bce629757cba1a177feacf339573f0 Mon Sep 17 00:00:00 2001 From: Colin Gravill Date: Tue, 24 Dec 2019 10:42:56 +0000 Subject: [PATCH 9/9] .NET Core 3.1.100 for Travis Just need >3.x for local tools --- .travis.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 5f40cde..42544f8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,8 +6,7 @@ services: - docker dist: xenial -#dotnet >2.2.* currently fail on unpack -dotnet: 2.2.402 +dotnet: 3.1.100 script: - ./build.sh --target BuildNetFramework