@@ -4,6 +4,31 @@ name: Build
44
55on :
66 workflow_call :
7+ inputs :
8+ publish :
9+ type : boolean
10+ default : false
11+ secrets :
12+ AZURE_CLIENT_ID :
13+ required : false
14+ AZURE_CLIENT_SECRET :
15+ required : false
16+ AZURE_TENANT_ID :
17+ required : false
18+ DOWNLOADS_HOSTGATOR_DOT_MIXXX_DOT_ORG_KEY :
19+ required : false
20+ DOWNLOADS_HOSTGATOR_DOT_MIXXX_DOT_ORG_KEY_PASSWORD :
21+ required : false
22+ MACOS_CODESIGN_CERTIFICATE_P12_BASE64 :
23+ required : false
24+ MACOS_CODESIGN_CERTIFICATE_PASSWORD :
25+ required : false
26+ MACOS_NOTARIZATION_APP_SPECIFIC_PASSWORD :
27+ required : false
28+ NETLIFY_BUILD_HOOK :
29+ required : false
30+ RRYAN_AT_MIXXX_DOT_ORG_GPG_PRIVATE_KEY :
31+ required : false
732
833permissions :
934 contents : read # to fetch code (actions/checkout)
4974 -DQML=OFF
5075 -DWAVPACK=ON
5176 -DVCPKG_TARGET_TRIPLET=x64-osx-min1100-release
52- -DVCPKG_DEFAULT_HOST_TRIPLET=x64-osx-min1100-release
5377 # TODO: Fix this broken test on macOS
5478 ctest_args : --exclude-regex DirectoryDAOTest.relocateDirectory
5579 cpack_generator : DragNDrop
7498 -DQML=ON
7599 -DWAVPACK=ON
76100 -DVCPKG_TARGET_TRIPLET=arm64-osx-min1100-release
77- -DVCPKG_DEFAULT_HOST_TRIPLET=x64-osx-min1100-release
78101 # TODO: Fix this broken test on macOS
79102 crosscompile : true
80103 cpack_generator : DragNDrop
@@ -103,7 +126,6 @@ jobs:
103126 -DQML=ON
104127 -DWAVPACK=ON
105128 -DVCPKG_TARGET_TRIPLET=x64-windows-release
106- -DVCPKG_DEFAULT_HOST_TRIPLET=x64-windows-release
107129 cc : cl
108130 cxx : cl
109131 # TODO: Fix these broken tests on Windows
@@ -400,8 +422,8 @@ jobs:
400422 if : always() && steps.package.outcome == 'failure' && runner.os == 'windows'
401423 uses : actions/upload-artifact@v4
402424 with :
403- name : logs-packages-wix
404- path : D:/a/mixxx/mixxx /build/_CPack_Packages/win64/WIX/wix.log
425+ name : ${{ matrix.os }}- logs-packages-wix
426+ path : ${{ github.workspace }} /build/_CPack_Packages/win64/WIX/wix.log
405427
406428 - name : " [Ubuntu] Import PPA GPG key"
407429 if : startsWith(matrix.os, 'ubuntu') && env.RRYAN_AT_MIXXX_DOT_ORG_GPG_PRIVATE_KEY != null
@@ -458,7 +480,7 @@ jobs:
458480 # also generates metadata for file artifact and write it to the job
459481 # output using the artifacts_slug value.
460482 id : prepare_deploy
461- if : github.event_name == 'push' && matrix.artifacts_path != null
483+ if : inputs.publish && matrix.artifacts_path != null
462484 shell : bash
463485 run : >
464486 if [[ "${GITHUB_REF}" =~ ^refs/tags/.* ]];
@@ -479,7 +501,7 @@ jobs:
479501 - name : " [Windows] Install rsync and openssh"
480502 env :
481503 SSH_PRIVATE_KEY : ${{ secrets.DOWNLOADS_HOSTGATOR_DOT_MIXXX_DOT_ORG_KEY }}
482- if : runner.os == 'Windows' && github.event_name == 'push' && env.SSH_PRIVATE_KEY != null
504+ if : runner.os == 'Windows' && inputs.publish && env.SSH_PRIVATE_KEY != null
483505 run : |
484506 if (Test-Path "C:\msys64\usr\bin") {
485507 $msysPath="C:\msys64"
@@ -514,7 +536,7 @@ jobs:
514536 Add-Content -Path "$Env:GITHUB_ENV" -Value "PATH=$Env:PATH"
515537
516538 - name : " Set up SSH Agent"
517- if : github.event_name == 'push' && env.SSH_PRIVATE_KEY != null
539+ if : inputs.publish && env.SSH_PRIVATE_KEY != null
518540 shell : bash
519541 env :
520542 SSH_AUTH_SOCK : /tmp/ssh_agent.sock
@@ -529,7 +551,7 @@ jobs:
529551
530552 - name : " [macOS/Windows] Upload build to downloads.mixxx.org"
531553 # skip deploying Ubuntu builds to downloads.mixxx.org because these are deployed to the PPA
532- if : runner.os != 'Linux' && github.event_name == 'push' && env.SSH_AUTH_SOCK != null
554+ if : runner.os != 'Linux' && inputs.publish && env.SSH_AUTH_SOCK != null
533555 shell : bash --login -eo pipefail "{0}"
534556 run : rsync --verbose --recursive --checksum --times --delay-updates "deploy/" "${SSH_USER}@${SSH_HOST}:${DESTDIR}/"
535557 env :
@@ -575,7 +597,7 @@ jobs:
575597 - name : " Collect Artifacts Metadata & Write Manifest"
576598 # Retrieve the metadata from the matrix job's outputs, merge them into a
577599 # single JSON document and then deploy to the server.
578- if : github.event_name == 'push' && env.SSH_PASSWORD != null
600+ if : inputs.publish && env.SSH_PASSWORD != null
579601 run : >
580602 if [[ "${GITHUB_REF}" =~ ^refs/tags/.* ]];
581603 then
@@ -593,7 +615,7 @@ jobs:
593615 SSH_PASSWORD : ${{ secrets.DOWNLOADS_HOSTGATOR_DOT_MIXXX_DOT_ORG_KEY_PASSWORD }}
594616
595617 - name : " Set up SSH Agent"
596- if : github.event_name == 'push' && env.SSH_PRIVATE_KEY != null && env.MANIFEST_DIRTY != null && env.MANIFEST_DIRTY != '0'
618+ if : inputs.publish && env.SSH_PRIVATE_KEY != null && env.MANIFEST_DIRTY != null && env.MANIFEST_DIRTY != '0'
597619 shell : bash
598620 env :
599621 SSH_AUTH_SOCK : /tmp/ssh_agent.sock
@@ -607,7 +629,7 @@ jobs:
607629 echo "SSH_AUTH_SOCK=${SSH_AUTH_SOCK}" >> "${GITHUB_ENV}"
608630
609631 - name : " Deploy Manifest"
610- if : github.event_name == 'push' && env.SSH_AUTH_SOCK != null
632+ if : inputs.publish && env.SSH_AUTH_SOCK != null
611633 shell : bash
612634 run : rsync --verbose --recursive --checksum --times --delay-updates "deploy/" "${SSH_USER}@${SSH_HOST}:${DESTDIR}/"
613635 env :
0 commit comments