diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 6177114..ac90162 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -2,7 +2,7 @@ name: master on: push: - branches: [ master ] + branches: [master] jobs: build: @@ -24,11 +24,11 @@ jobs: - name: Update version if: steps.changes.outputs.buildprops == 'false' run: | - (Get-Content Directory.Build.props) | % { - $m = [regex]::match($_, '(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?'); - if(!$m.Success -or $m.Groups[4].Success -or $m.Groups[5].Success) { $_; } - else { $_ -replace $m.Value, ("{0}.{1}.{2}-pre${{ github.run_number }}" -f $m.Groups[1].Value,$m.Groups[2].Value,([convert]::ToInt32($m.Groups[3].Value)+1)); } - } | Set-Content Directory.Build.props + (Get-Content Directory.Build.props) | % { + $m = [regex]::match($_, '(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?'); + if(!$m.Success -or $m.Groups[4].Success -or $m.Groups[5].Success) { $_; } + else { $_ -replace $m.Value, ("{0}.{1}.{2}-pre${{ github.run_number }}" -f $m.Groups[1].Value,$m.Groups[2].Value,([convert]::ToInt32($m.Groups[3].Value)+1)); } + } | Set-Content Directory.Build.props - name: NuGet restore run: nuget restore LibreHardwareMonitor.sln @@ -57,6 +57,13 @@ jobs: path: | bin/Release/net6.0 + - name: Publish net70 + uses: actions/upload-artifact@v2 + with: + name: LibreHardwareMonitorLib-net70 + path: | + bin/Release/net7.0 + - name: Publish nupkg uses: actions/upload-artifact@v2 with: diff --git a/.github/workflows/pull requests.yml b/.github/workflows/pull requests.yml index 15682f7..7a2437c 100644 --- a/.github/workflows/pull requests.yml +++ b/.github/workflows/pull requests.yml @@ -2,7 +2,7 @@ name: pull requests on: pull_request: - branches: [ master ] + branches: [master] jobs: build: @@ -23,15 +23,15 @@ jobs: - name: Update version if: steps.changes.outputs.buildprops == 'false' run: | - (Get-Content Directory.Build.props) | % { - $m = [regex]::match($_, '(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?'); - if(!$m.Success -or $m.Groups[4].Success -or $m.Groups[5].Success) { $_; } - else { $_ -replace $m.Value, ("{0}.{1}.{2}-ci${{ github.run_number }}" -f $m.Groups[1].Value,$m.Groups[2].Value,([convert]::ToInt32($m.Groups[3].Value)+1)); } - } | Set-Content Directory.Build.props + (Get-Content Directory.Build.props) | % { + $m = [regex]::match($_, '(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?'); + if(!$m.Success -or $m.Groups[4].Success -or $m.Groups[5].Success) { $_; } + else { $_ -replace $m.Value, ("{0}.{1}.{2}-ci${{ github.run_number }}" -f $m.Groups[1].Value,$m.Groups[2].Value,([convert]::ToInt32($m.Groups[3].Value)+1)); } + } | Set-Content Directory.Build.props - name: NuGet restore run: nuget restore LibreHardwareMonitor.sln - + - name: Build run: msbuild LibreHardwareMonitor.sln -p:Configuration=Release -m @@ -48,7 +48,7 @@ jobs: name: LibreHardwareMonitorLib-netstandard20 path: | bin/Release/netstandard2.0 - + - name: Publish net60 uses: actions/upload-artifact@v2 with: @@ -56,6 +56,13 @@ jobs: path: | bin/Release/net6.0 + - name: Publish net70 + uses: actions/upload-artifact@v2 + with: + name: LibreHardwareMonitorLib-net70 + path: | + bin/Release/net7.0 + - name: Publish nupkg uses: actions/upload-artifact@v2 with: diff --git a/LibreHardwareMonitorLib/LibreHardwareMonitorLib.csproj b/LibreHardwareMonitorLib/LibreHardwareMonitorLib.csproj index bda6207..c82d813 100644 --- a/LibreHardwareMonitorLib/LibreHardwareMonitorLib.csproj +++ b/LibreHardwareMonitorLib/LibreHardwareMonitorLib.csproj @@ -1,6 +1,6 @@ - net472;netstandard2.0;net6.0 + net472;netstandard2.0;net6.0;net7.0 LibreHardwareMonitorLib LibreHardwareMonitor true diff --git a/README.md b/README.md index 52412fc..b8459bb 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ Libre Hardware Monitor, a fork of Open Hardware Monitor, is free software that c | Name| .NET | Build Status | | --- | --- | --- | | **LibreHardwareMonitor**
Windows Forms based application that presents all data in a graphical interface | .NET Framework 4.7.2 | [![Build status](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/workflows/CI/badge.svg)](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/actions) | -| **LibreHardwareMonitorLib**
Library that allows you to use all features in your own application | .NET Framework 4.7.2 and .NET 6.0 | [![Build status](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/workflows/CI/badge.svg)](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/actions) | +| **LibreHardwareMonitorLib**
Library that allows you to use all features in your own application | .NET Framework 4.7.2, .NET 6.0, and .NET 7.0 | [![Build status](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/workflows/CI/badge.svg)](https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/actions) | ## What can it do? You can read information from devices such as: