diff --git a/.github/workflows/dotnet-build.yml b/.github/workflows/dotnet-build.yml index 3e9e95bd..c87d1613 100644 --- a/.github/workflows/dotnet-build.yml +++ b/.github/workflows/dotnet-build.yml @@ -31,6 +31,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 + submodules: true # Set up a VS build environment. - name: Setup Environment Variables @@ -64,9 +65,9 @@ jobs: run: .\build\Install-WindowsSdkISO.ps1 18362 shell: pwsh - # Run the build. + # Run the build. Pushes to main and rel/* also build the full multi-arch sample app bundles. - name: Build - run: .\build.ps1 --target=Package + run: .\build.ps1 --target=Package ${{ github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/rel/')) && '--fullAppBuild=true' || '' }} shell: pwsh working-directory: .\build diff --git a/build/build.cake b/build/build.cake index d881231a..1c27469a 100644 --- a/build/build.cake +++ b/build/build.cake @@ -11,6 +11,8 @@ using System.Text.RegularExpressions; var target = Argument("target", "Default"); var configuration = Argument("configuration", "Release"); +// Builds the sample app bundles for every architecture. Slow; not needed for the NuGet packages. +var fullAppBuild = Argument("fullAppBuild", false); ////////////////////////////////////////////////////////////////////// // VERSIONS OF TOOLS TO USE @@ -61,6 +63,10 @@ void MSBuildSolution( { settings = settings.WithProperty(property.Name, property.Value); } + if (!fullAppBuild) + { + settings = settings.WithProperty("AppxBundle", "Never"); + } return settings; } @@ -94,6 +100,7 @@ static bool IsExcludedDirectory(FilePath path) return segments.Contains("bin") || + segments.Contains("external") || segments.Contains("internal") || segments.Contains("obj"); }