Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 34 additions & 37 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,53 @@ version: 2.1
executors:
dotnet:
docker:
- image: mcr.microsoft.com/dotnet/core/sdk:2.1
- image: mcr.microsoft.com/dotnet/core/sdk:3.1
environment:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "true"
NUGET_XMLDOC_MODE: skip
BUILD_CONFIG: Release
CIRCLE_TEST_REPORTS: /workspace/circleci-test-results
dotnet3:
docker:
- image: mcr.microsoft.com/dotnet/core/sdk:3.0
environment:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "true"
NUGET_XMLDOC_MODE: skip
go:
docker:
- image: circleci/golang

workflows:
build-and-push:
jobs:
- build-test:
filters:
tags:
only: /.*/
- build-singlepackage:
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/
- build-push:
requires:
- build-singlepackage
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/
- upload-github:
requires:
- build-singlepackage
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/

jobs:
build-test:
executor: dotnet
steps:
- checkout
- run: dotnet tool install -g dotnet-reportgenerator-globaltool
- run: dotnet build -c Debug
- run: dotnet test -c Debug --no-build -p:CollectCoverage=true -p:CoverletOutputFormat=opencover --test-adapter-path:. --logger:"xunit;LogFilePath=results.xml"
- run: dotnet test -c Debug --no-build -p:CollectCoverage=true -p:CoverletOutputFormat=opencover --test-adapter-path:. --logger:"xunit;LogFilePath=results.xml" < /dev/null
- run: curl -s https://codecov.io/bash > codecov
- run: chmod +x codecov
- run: ./codecov -f ./src/MySQLToCsharp.Tests/coverage.opencover.xml
Expand All @@ -48,7 +72,7 @@ jobs:
path: ./src/MySQLToCsharp/bin/Release
destination: ./MySQLToCsharp/
build-singlepackage:
executor: dotnet3
executor: dotnet
steps:
- checkout
- run: dotnet publish ./src/MySQLToCsharp/ -c Release -o ./MySQLToCsharp -r win-x64 -p:PublishSingleFile=true -p:Version=${CIRCLE_TAG}
Expand All @@ -67,30 +91,3 @@ jobs:
- run: ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -delete ${CIRCLE_TAG} ./artifacts/MySQLToCsharp/
- store_artifacts:
path: ./artifacts/MySQLToCsharp
workflows:
build-and-push:
jobs:
- build-test:
filters:
tags:
only: /.*/
- build-push:
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/
- build-singlepackage:
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/
- upload-github:
requires:
- build-singlepackage
filters:
tags:
only: /^\d+\.\d+\.\d+$/
branches:
ignore: /.*/
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.1</TargetFramework>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>

</Project>
17 changes: 9 additions & 8 deletions src/MySQLToCsharp.Tests/MySQLToCsharp.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp2.1</TargetFramework>

<IsPackable>false</IsPackable>
<TargetFrameworks>netcoreapp3.1</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="coverlet.msbuild" Version="2.6.3">
<PackageReference Include="coverlet.msbuild" Version="2.8.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="FluentAssertions" Version="5.7.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.0.1" />
<PackageReference Include="FluentAssertions" Version="5.10.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.4.0" />
<PackageReference Include="RandomFixtureKit" Version="1.0.0" />
<PackageReference Include="xunit" Version="2.4.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="XunitXml.TestLogger" Version="2.1.26" />
</ItemGroup>

Expand Down
5 changes: 2 additions & 3 deletions src/MySQLToCsharp/MySQLToCsharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.1</TargetFramework>
<TargetFramework>netcoreapp3.1</TargetFramework>
<LangVersion>latest</LangVersion>
<Version>0.1.0</Version>
<AssemblyVersion>$(Version)</AssemblyVersion>
Expand All @@ -26,7 +26,6 @@

<PropertyGroup Condition="'$(PublishSingleFile)' == 'true'">
<AssemblyName>MySQLToCsharp_$(RuntimeIdentifier)_$(Version)</AssemblyName>
<TargetFramework>netcoreapp3.0</TargetFramework>
<PublishSingleFile>true</PublishSingleFile>
<PublishTrimmed>true</PublishTrimmed>
<IncludeSymbolsInSingleFile>true</IncludeSymbolsInSingleFile>
Expand All @@ -41,7 +40,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Antlr4.Runtime.Standard" Version="4.7.2" />
<PackageReference Include="Antlr4.Runtime.Standard" Version="4.8.0" />
<PackageReference Include="MicroBatchFramework" Version="1.2.0" />
</ItemGroup>

Expand Down