diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f149718e..fc1ce852 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -191,6 +191,7 @@ jobs: # Checkout ITK-SNAP code - name: Checkout code + if: ${{ github.event_name == 'workflow_dispatch' && inputs.use_cached_itksnap_build }} uses: actions/checkout@v4 with: submodules: true @@ -199,6 +200,7 @@ jobs: # Configure ITK-SNAP - name: Configure ITK-SNAP + if: ${{ github.event_name == 'workflow_dispatch' && inputs.use_cached_itksnap_build }} uses: threeal/cmake-action@v2.0.0 continue-on-error: true with: @@ -218,6 +220,7 @@ jobs: # Build ITK-SNAP using CDash - name: Build and Test ITK-SNAP + if: ${{ github.event_name == 'workflow_dispatch' && inputs.use_cached_itksnap_build }} working-directory: ${{github.workspace}}/itksnap/build run: | ${{ matrix.test_pref }} ctest -D ExperimentalStart @@ -228,6 +231,7 @@ jobs: # Cache the ITK-SNAP build - name: Cache ITK-SNAP build directory + if: ${{ github.event_name == 'workflow_dispatch' && inputs.use_cached_itksnap_build }} uses: actions/cache/save@v4 with: path: ${{github.workspace}}/itksnap @@ -237,7 +241,7 @@ jobs: - name: Package ITK-SNAP working-directory: ${{github.workspace}}/itksnap/build run: | - cmake --build -t package + cmake --build -- -t package - name: Setup tmate session uses: mxschmitt/action-tmate@v3