Skip to content

Commit

Permalink
Merge pull request #35 from max-ieremenko/feature/net8.0
Browse files Browse the repository at this point in the history
target .net8.0
  • Loading branch information
max-ieremenko authored Nov 12, 2023
2 parents d39ed62 + 9ff2f94 commit 2f197e2
Show file tree
Hide file tree
Showing 66 changed files with 127 additions and 73 deletions.
4 changes: 2 additions & 2 deletions Build/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
build.ps1 is designed to run on windows

- PowerShell Desktop 5.1
- PowerShell [7.3.0](https://github.com/PowerShell/PowerShell/releases/tag/v7.3.0) for .net 7.0 tests
- PowerShell [7.3.0](https://github.com/PowerShell/PowerShell/releases/tag/v7.3.0) for .net 7.0 and 8.0 tests
- PowerShell [7.2.1](https://github.com/PowerShell/PowerShell/releases/tag/v7.2.1) for .net 6.0 tests
- Install-Module -Name [InvokeBuild](https://www.powershellgallery.com/packages/InvokeBuild/5.10.4) -RequiredVersion 5.10.4
- Install-Module -Name [ThirdPartyLibraries](https://www.powershellgallery.com/packages/ThirdPartyLibraries/3.4.1) -RequiredVersion 3.4.1
- .net framework 4.7.2+ sdk
- .net 7.0 sdk
- .net 8.0 sdk
- docker, switched to linux containers

## How to build
Expand Down
1 change: 1 addition & 0 deletions Build/install-dependencies.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ $ErrorActionPreference = "Stop"

if (".net" -in $List) {
Invoke-InstallDotNet -Version "6.0.319"
Invoke-InstallDotNet -Version "7.0.100"

$version = (Get-Content -Raw (Join-Path $PSScriptRoot "../Sources/global.json") | ConvertFrom-Json).sdk.version
Invoke-InstallDotNet -Version $version
Expand Down
11 changes: 9 additions & 2 deletions Build/tasks/build-tasks.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ task Initialize {
repositoryCommitId = git rev-parse HEAD
}

$script:frameworks = "net472", "net6.0", "net7.0"
$script:frameworks = "net472", "net6.0", "net7.0", "net8.0"
$script:databases = "MsSql", "PgSql", "MySql"

Write-Output "PackageVersion: $($settings.version)"
Expand Down Expand Up @@ -109,6 +109,7 @@ task PackNuget472 PackPoweShellModule, {

task PackManualDownload PackGlobalTool, PackPoweShellModule, {
Get-ChildItem -Path $settings.bin -Recurse -Directory -Filter "publish" | Remove-Item -Force -Recurse
Get-ChildItem -Path $settings.bin -Recurse -Directory -Filter "win-arm64" | Remove-Item -Force -Recurse

$out = $settings.artifacts
$lic = Join-Path $settings.sources "..\LICENSE.md"
Expand Down Expand Up @@ -205,6 +206,10 @@ task PsCoreTest {
, "mcr.microsoft.com/powershell:7.2.2-ubuntu-20.04"
, "mcr.microsoft.com/powershell:7.3-ubuntu-20.04")

foreach ($image in $images) {
exec { docker pull $image }
}

$builds = @()
foreach ($image in $images) {
foreach ($database in $databases) {
Expand All @@ -223,7 +228,8 @@ task PsCoreTest {
task SdkToolTest {
$images = $(
"sqldatabase/dotnet_pwsh:6.0-sdk"
, "sqldatabase/dotnet_pwsh:7.0-sdk")
, "sqldatabase/dotnet_pwsh:7.0-sdk"
, "sqldatabase/dotnet_pwsh:8.0-sdk")

$builds = @()
foreach ($image in $images) {
Expand All @@ -244,6 +250,7 @@ task NetRuntimeLinuxTest {
$testCases = $(
@{ targetFramework = "net6.0"; image = "sqldatabase/dotnet_pwsh:6.0-runtime" }
, @{ targetFramework = "net7.0"; image = "sqldatabase/dotnet_pwsh:7.0-runtime" }
, @{ targetFramework = "net8.0"; image = "sqldatabase/dotnet_pwsh:8.0-runtime" }
)

$builds = @()
Expand Down
2 changes: 1 addition & 1 deletion Build/tasks/build-tasks.unit-test.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ param(
$Sources,

[Parameter(Mandatory)]
[ValidateSet("net472", "net6.0", "net7.0")]
[ValidateSet("net472", "net6.0", "net7.0", "net8.0")]
[string]
$Framework
)
Expand Down
24 changes: 23 additions & 1 deletion Build/tasks/create-images-tasks.ps1
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
task Default `
BuildDotnetSdk60 `
, BuildDotnetRuntime60 `
, BuildDotnetSdk70 `
, BuildDotnetSdk80 `
, BuildDotnetRuntime60 `
, BuildDotnetRuntime70 `
, BuildDotnetRuntime80 `
, BuildMsSqlDatabase `
, BuildPgSqlDatabase `
, BuildMySqlDatabase
Expand Down Expand Up @@ -79,4 +81,24 @@ task BuildDotnetRuntime70 {
-t sqldatabase/dotnet_pwsh:7.0-runtime `
.
}
}

task BuildDotnetSdk80 {
$dockerfile = Join-Path $context "image-dotnet-sdk-8.0.dockerfile"
exec {
docker build `
-f $dockerfile `
-t sqldatabase/dotnet_pwsh:8.0-sdk `
.
}
}

task BuildDotnetRuntime80 {
$dockerfile = Join-Path $context "image-dotnet-runtime-8.0.dockerfile"
exec {
docker build `
-f $dockerfile `
-t sqldatabase/dotnet_pwsh:8.0-runtime `
.
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Dapper.StrongName [2.1.15](https://www.nuget.org/packages/Dapper.StrongName/2.1.

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [Apache-2.0](../../../../licenses/apache-2.0)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.CodeCoverage [17.7.2](https://www.nuget.org/packages/Microsoft.CodeCov

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [ms-net-library](../../../../licenses/ms-net-library)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
],
"Dependencies": [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.NET.Test.Sdk [17.7.2](https://www.nuget.org/packages/Microsoft.NET.Tes

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [ms-net-library](../../../../licenses/ms-net-library)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
],
"Dependencies": [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.TestPlatform.ObjectModel [17.7.2](https://www.nuget.org/packages/Micro

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [ms-net-library](../../../../licenses/ms-net-library)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
],
"Dependencies": [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.TestPlatform.TestHost [17.7.2](https://www.nuget.org/packages/Microsof

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [ms-net-library](../../../../licenses/ms-net-library)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
],
"Dependencies": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.Win32.Registry [4.7.0](https://www.nuget.org/packages/Microsoft.Win32.

Used by: SqlDatabase

Target frameworks: net472, net6.0, net7.0, netstandard2.0
Target frameworks: net472, net6.0, net7.0, net8.0, netstandard2.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.WSMan.Runtime [7.2.0](https://www.nuget.org/packages/Microsoft.WSMan.R

Used by: SqlDatabase

Target frameworks: net472, net6.0, net7.0, netstandard2.0
Target frameworks: net472, net6.0, net7.0, net8.0, netstandard2.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft.WSMan.Runtime [7.3.0](https://www.nuget.org/packages/Microsoft.WSMan.R

Used by: SqlDatabase

Target frameworks: net472, net6.0, net7.0, netstandard2.0
Target frameworks: net472, net6.0, net7.0, net8.0, netstandard2.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ NETStandard.Library [2.0.3](https://www.nuget.org/packages/NETStandard.Library/2

Used by: SqlDatabase

Target frameworks: net472, net6.0, net7.0, netstandard2.0
Target frameworks: net472, net6.0, net7.0, net8.0, netstandard2.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Newtonsoft.Json [13.0.1](https://www.nuget.org/packages/Newtonsoft.Json/13.0.1)

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Newtonsoft.Json [13.0.3](https://www.nuget.org/packages/Newtonsoft.Json/13.0.3)

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ NuGet.Frameworks [6.5.0](https://www.nuget.org/packages/NuGet.Frameworks/6.5.0)

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [Apache-2.0](../../../../licenses/apache-2.0)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ NUnit [3.14.0](https://www.nuget.org/packages/NUnit/3.14.0)

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"TargetFrameworks": [
"net472",
"net6.0",
"net7.0"
"net7.0",
"net8.0"
]
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ NUnit3TestAdapter [4.5.0](https://www.nuget.org/packages/NUnit3TestAdapter/4.5.0

Used by: SqlDatabase internal

Target frameworks: net472, net6.0, net7.0
Target frameworks: net472, net6.0, net7.0, net8.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ PowerShellStandard.Library [5.1.0](https://www.nuget.org/packages/PowerShellStan

Used by: SqlDatabase

Target frameworks: net472, net6.0, net7.0, netstandard2.0
Target frameworks: net472, net6.0, net7.0, net8.0, netstandard2.0

License: [MIT](../../../../licenses/mit)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"net472",
"net6.0",
"net7.0",
"net8.0",
"netstandard2.0"
]
}
Expand Down
Loading

0 comments on commit 2f197e2

Please sign in to comment.