Skip to content

Commit

Permalink
Retarget Projects to .NET 6 (#1)
Browse files Browse the repository at this point in the history
* Add .NET 6 target to projects

* Remove multi target

* Revert unecessary change
  • Loading branch information
migafgarcia authored Nov 12, 2021
1 parent fb38917 commit be1e04e
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/dotnetcore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.101
dotnet-version: 6.x

- name: Test with dotnet
run: dotnet test --configuration Release
Expand All @@ -36,13 +36,13 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.101
dotnet-version: 6.x

- name: Determine version
run: echo "::set-env name=VERSION::$(git describe --tags --dirty)"

- name: Publish with dotnet
run: dotnet publish src/Cmf.Tools.TestDetector.Console/Cmf.Tools.TestDetector.Console.csproj --output win-64x/ -r win-x64 --configuration Release /p:PublishSingleFile=true /p:IncludeSymbolsInSingleFile=true /p:UseAppHost=true /p:Version=$VERSION
run: dotnet publish src/Cmf.Tools.TestDetector.Console/Cmf.Tools.TestDetector.Console.csproj --output win-64x/ -r win-x64 --self-contained --configuration Release /p:PublishSingleFile=true /p:UseAppHost=true /p:Version=$VERSION

- name: Create zip
run: zip -r '../win-64x.zip' *
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"profiles": {
"Cmf.Tools.TestDetector.Console": {
"commandName": "Project",
"commandLineArgs": "--repositorypath=\"\" --testsolutionpath=\"\" --testcategory=\"\" --sourcecommitid=\"\" --targetcommitid=\"\""
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,8 @@ public async Task<bool> TryAddCategoryToTestMethod(string filePath, int lineNumb
throw new ArgumentOutOfRangeException(nameof(filePath));
}

_logger.Info($"Adding category {category} to file {filePath}");

var method = await FindMethod(roslynNode, lineNumber).ConfigureAwait(false);

if (method == null)
Expand Down Expand Up @@ -365,6 +367,8 @@ public async Task Initialize(Solution solution)
throw new ArgumentNullException(nameof(solution));
}

_logger.Debug($"Initializing solution {solution.FilePath}");

_solution = solution;
ProjectDependencyGraph projectGraph = solution.GetProjectDependencyGraph();

Expand Down
2 changes: 1 addition & 1 deletion src/Cmf.Tools.TestDetector/Cmf.Tools.TestDetector.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<Company>Critical Manufacturing</Company>
<Product>CMF Dev Test Detector</Product>
<Authors>Critical Manufacturing</Authors>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>

<IsPackable>false</IsPackable>
</PropertyGroup>
Expand Down

0 comments on commit be1e04e

Please sign in to comment.