[ci] Split debug and release Windows builds (#4277)

Co-authored-by: Tyler Veness <calcmogul@gmail.com>
This commit is contained in:
Thad House
2022-06-06 17:25:02 -07:00
committed by GitHub
parent abb45a68db
commit 17752f1337
6 changed files with 21 additions and 6 deletions

View File

@@ -52,11 +52,20 @@ jobs:
matrix:
include:
- os: windows-2019
artifact-name: Win64
artifact-name: Win64Debug
architecture: x64
task: "build"
build-options: "-PciDebugOnly"
- os: windows-2019
artifact-name: Win64Release
architecture: x64
build-options: "-PciReleaseOnly"
task: "copyAllOutputs"
- os: macOS-11
artifact-name: macOS
architecture: x64
build-options: ""
task: "build"
name: "Build - ${{ matrix.artifact-name }}"
runs-on: ${{ matrix.os }}
steps:
@@ -86,7 +95,7 @@ jobs:
shell: bash
if: startsWith(github.ref, 'refs/tags/v')
- name: Build with Gradle
run: ./gradlew build --build-cache -PbuildServer -PskipJavaFormat ${{ env.EXTRA_GRADLE_ARGS }}
run: ./gradlew ${{ matrix.task }} --build-cache -PbuildServer -PskipJavaFormat ${{ matrix.build-options }} ${{ env.EXTRA_GRADLE_ARGS }}
env:
ARTIFACTORY_PUBLISH_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }}
ARTIFACTORY_PUBLISH_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }}

View File

@@ -87,7 +87,12 @@ task copyAllOutputs(type: Copy) {
build.dependsOn copyAllOutputs
copyAllOutputs.dependsOn outputVersions
def copyReleaseOnly = project.hasProperty('ciReleaseOnly')
ext.addTaskToCopyAllOutputs = { task ->
if (copyReleaseOnly && task.name.contains('debug')) {
return
}
copyAllOutputs.dependsOn task
copyAllOutputs.inputs.file task.archivePath
copyAllOutputs.from task.archivePath

View File

@@ -5,5 +5,5 @@ repositories {
}
}
dependencies {
implementation "edu.wpi.first:native-utils:2023.0.1"
implementation "edu.wpi.first:native-utils:2023.0.2"
}

View File

@@ -41,7 +41,6 @@ dependencies {
model {
components {
multiCameraServerCpp(NativeExecutableSpec) {
targetBuildTypes 'release'
sources {
cpp {
source {

View File

@@ -2,6 +2,10 @@ import org.gradle.internal.os.OperatingSystem
nativeUtils.skipInstallPdb = project.hasProperty('buildServer')
if (project.hasProperty('ciDebugOnly')) {
toolchainsPlugin.registerReleaseBuildType = false
}
nativeUtils.addWpiNativeUtils()
nativeUtils.withRoboRIO()
nativeUtils.withRaspbian()

View File

@@ -235,7 +235,6 @@ model {
}
}
netconsoleServer(NativeExecutableSpec) {
targetBuildTypes 'release'
sources {
cpp {
source {
@@ -255,7 +254,6 @@ model {
}
}
netconsoleTee(NativeExecutableSpec) {
targetBuildTypes 'release'
sources {
cpp {
source {