From 8c1405e684e4d2cad723ac245ccdef23a3431b65 Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 08:56:10 +0200 Subject: [PATCH 1/7] Try fixing GitVersion when running parallel builds --- .github/workflows/features-prs.yml | 12 ++++++------ .github/workflows/release-beta.yml | 12 ++++++------ src/BlazorLazyLoading.sln | 1 + src/nuget/Directory.Build.props | 1 + src/nuget/GitVersion.proj_ | 17 +++++++++++++++++ src/nuget/NugetCommon.props | 21 +++++++++++++-------- 6 files changed, 44 insertions(+), 20 deletions(-) create mode 100644 src/nuget/GitVersion.proj_ diff --git a/.github/workflows/features-prs.yml b/.github/workflows/features-prs.yml index be4f52d..43baa07 100644 --- a/.github/workflows/features-prs.yml +++ b/.github/workflows/features-prs.yml @@ -34,25 +34,25 @@ jobs: dotnet-version: 3.1.200 - name: Restore library - run: dotnet restore src/BlazorLazyLoading.sln --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet restore src/BlazorLazyLoading.sln -p:BLLUseLocalNugetPackages=true - name: Build library - run: dotnet build src/BlazorLazyLoading.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet build src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Test library run: dotnet test src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Pack library - run: dotnet pack src/BlazorLazyLoading.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet pack src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Restore demo - run: dotnet restore demo/Demo.sln --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet restore demo/Demo.sln -p:BLLUseLocalNugetPackages=true - name: Build demo - run: dotnet build demo/Demo.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet build demo/Demo.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Publish demo - run: dotnet publish demo/ServerHost/ServerHost.csproj -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true -o output/demo + run: dotnet publish demo/ServerHost/ServerHost.csproj -c Release -p:BLLUseLocalNugetPackages=true -o output/demo - name: Test demo run: dotnet test demo/Demo.sln -c Release -p:BLLUseLocalNugetPackages=true diff --git a/.github/workflows/release-beta.yml b/.github/workflows/release-beta.yml index b4e6da9..488eaa1 100644 --- a/.github/workflows/release-beta.yml +++ b/.github/workflows/release-beta.yml @@ -33,25 +33,25 @@ jobs: dotnet-version: 3.1.200 - name: Restore library - run: dotnet restore src/BlazorLazyLoading.sln --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet restore src/BlazorLazyLoading.sln -p:BLLUseLocalNugetPackages=true - name: Build library - run: dotnet build src/BlazorLazyLoading.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet build src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Test library run: dotnet test src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Pack library - run: dotnet pack src/BlazorLazyLoading.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet pack src/BlazorLazyLoading.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Restore demo - run: dotnet restore demo/Demo.sln --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet restore demo/Demo.sln -p:BLLUseLocalNugetPackages=true - name: Build demo - run: dotnet build demo/Demo.sln -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true + run: dotnet build demo/Demo.sln -c Release -p:BLLUseLocalNugetPackages=true - name: Publish demo - run: dotnet publish demo/ServerHost/ServerHost.csproj -c Release --disable-parallel -p:BLLUseLocalNugetPackages=true -o output/demo + run: dotnet publish demo/ServerHost/ServerHost.csproj -c Release -p:BLLUseLocalNugetPackages=true -o output/demo - name: Test demo run: dotnet test demo/Demo.sln -c Release -p:BLLUseLocalNugetPackages=true diff --git a/src/BlazorLazyLoading.sln b/src/BlazorLazyLoading.sln index d5a6063..59e4b63 100644 --- a/src/BlazorLazyLoading.sln +++ b/src/BlazorLazyLoading.sln @@ -17,6 +17,7 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "nuget", "nuget", "{593AE082-BD15-4FEB-8DC2-20D4ABA3AFD4}" ProjectSection(SolutionItems) = preProject nuget\Directory.Build.props = nuget\Directory.Build.props + nuget\GitVersion.proj_ = nuget\GitVersion.proj_ nuget\NugetCommon.props = nuget\NugetCommon.props EndProjectSection EndProject diff --git a/src/nuget/Directory.Build.props b/src/nuget/Directory.Build.props index 19f969e..501e1a4 100644 --- a/src/nuget/Directory.Build.props +++ b/src/nuget/Directory.Build.props @@ -12,6 +12,7 @@ + icon.png diff --git a/src/nuget/GitVersion.proj_ b/src/nuget/GitVersion.proj_ new file mode 100644 index 0000000..9776599 --- /dev/null +++ b/src/nuget/GitVersion.proj_ @@ -0,0 +1,17 @@ + + + + $(Temp)/$(SolutionName)/GitVersion/obj + $(Temp)/$(SolutionName)/GitVersion/bin + + + + + + all + runtime; build; native; contentfiles; analyzers + + + + + diff --git a/src/nuget/NugetCommon.props b/src/nuget/NugetCommon.props index 66928b5..2c73153 100644 --- a/src/nuget/NugetCommon.props +++ b/src/nuget/NugetCommon.props @@ -1,11 +1,4 @@ - - - - all - runtime; build; native; contentfiles; analyzers - - $(RepoDir)output\nuget @@ -32,7 +25,19 @@ Ivan Sanz Carasa (isc30) - + + + + + + + + $(Version) + + + + + $(NuspecProperties);configuration=$(Configuration) From 689a08dd9f75b80319a478d248537e2793aebb8c Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 09:01:41 +0200 Subject: [PATCH 2/7] Include branches with '/' to GitHub Actions --- .github/workflows/features-prs.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/features-prs.yml b/.github/workflows/features-prs.yml index 43baa07..1e4bc55 100644 --- a/.github/workflows/features-prs.yml +++ b/.github/workflows/features-prs.yml @@ -4,10 +4,12 @@ on: push: branches: - '*' + - '*/*' - '!master' # all branches except master pull_request: branches: - '*' + - '*/*' - '!master' # all branches except master env: From 51c9f0f7ff54b464331d3be876343bebd435150a Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 09:05:04 +0200 Subject: [PATCH 3/7] Simplify targets --- src/nuget/NugetCommon.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nuget/NugetCommon.props b/src/nuget/NugetCommon.props index 2c73153..3b0fc55 100644 --- a/src/nuget/NugetCommon.props +++ b/src/nuget/NugetCommon.props @@ -37,7 +37,7 @@ - + $(NuspecProperties);configuration=$(Configuration) From 76a156564da2c8ce1216d4be88562d72aeb0ab15 Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 09:29:44 +0200 Subject: [PATCH 4/7] Fix TMP folder in linux --- src/nuget/GitVersion.proj_ | 1 + 1 file changed, 1 insertion(+) diff --git a/src/nuget/GitVersion.proj_ b/src/nuget/GitVersion.proj_ index 9776599..8a42f80 100644 --- a/src/nuget/GitVersion.proj_ +++ b/src/nuget/GitVersion.proj_ @@ -1,6 +1,7 @@  + /tmp $(Temp)/$(SolutionName)/GitVersion/obj $(Temp)/$(SolutionName)/GitVersion/bin From c27d88f0cf358ab54503201626ffdf98e00a609d Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 09:36:31 +0200 Subject: [PATCH 5/7] Fix internal version from demo --- src/nuget/NugetCommon.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nuget/NugetCommon.props b/src/nuget/NugetCommon.props index 3b0fc55..a173631 100644 --- a/src/nuget/NugetCommon.props +++ b/src/nuget/NugetCommon.props @@ -57,7 +57,7 @@ - + From 7b7f5384b0d7b18bf6c360d7970d0206cfa4bff6 Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 09:57:41 +0200 Subject: [PATCH 6/7] Run GetVersion before build --- src/nuget/NugetCommon.props | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/nuget/NugetCommon.props b/src/nuget/NugetCommon.props index a173631..1413da7 100644 --- a/src/nuget/NugetCommon.props +++ b/src/nuget/NugetCommon.props @@ -25,7 +25,7 @@ Ivan Sanz Carasa (isc30) - + @@ -57,7 +57,7 @@ - + From 3f18f1998132dd652dcd0d0bcd5091ba0b73cfe9 Mon Sep 17 00:00:00 2001 From: isc30 Date: Fri, 29 May 2020 10:01:41 +0200 Subject: [PATCH 7/7] fetch version before pack --- src/nuget/NugetCommon.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nuget/NugetCommon.props b/src/nuget/NugetCommon.props index 1413da7..d3932a4 100644 --- a/src/nuget/NugetCommon.props +++ b/src/nuget/NugetCommon.props @@ -25,7 +25,7 @@ Ivan Sanz Carasa (isc30) - +