Skip to content

Commit 3a44014

Browse files
committed
Modernize CI build and bump net6.0 targets to net8.0
.NET 6 is end-of-support and was removed from the hosted windows-latest image, so the pipeline could no longer build or test. Bump the two test projects and WindowsImaging from net6.0 to net8.0 (LTS) and pin the SDK with an explicit UseDotNet@2 step. Replace the deprecated UseGitVersion@5 task with the GitVersion 6 setup/execute task pair. The existing GitVersion.yml validates and runs cleanly under GitVersion 6, so it is left unchanged.
1 parent ebd9f18 commit 3a44014

4 files changed

Lines changed: 15 additions & 5 deletions

File tree

azure-pipelines.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,19 @@ variables:
1515
buildConfiguration: 'Release'
1616

1717
steps:
18-
- task: UseGitVersion@5
18+
- task: UseDotNet@2
19+
displayName: install .NET SDK
1920
inputs:
20-
versionSpec: '5.x'
21+
packageType: sdk
22+
version: '8.0.x'
23+
24+
- task: gitversion/setup@3
25+
displayName: install GitVersion
26+
inputs:
27+
versionSpec: '6.x'
28+
29+
- task: gitversion/execute@3
30+
displayName: determine version
2131

2232
- task: DotNetCoreCLI@2
2333
inputs:

src/CloudInit.ConfigDrive.WindowsImaging/CloudInit.ConfigDrive.WindowsImaging.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0-windows</TargetFrameworks>
4+
<TargetFrameworks>net8.0-windows</TargetFrameworks>
55
<AssemblyName>Dbosoft.CloudInit.ConfigDrive.WindowsImaging</AssemblyName>
66
<RootNamespace>Dbosoft.CloudInit.ConfigDrive</RootNamespace>
77
<Nullable>enable</Nullable>

test/CloudInit.ConfigDrive.Core.Test/CloudInit.ConfigDrive.Core.Test.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0</TargetFrameworks>
4+
<TargetFrameworks>net8.0</TargetFrameworks>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

test/CloudInit.ConfigDrive.NoCloud.Test/CloudInit.ConfigDrive.Core.NoCloud.Test.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0</TargetFrameworks>
4+
<TargetFrameworks>net8.0</TargetFrameworks>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

0 commit comments

Comments
 (0)