diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6f8b55bd2..81079e598 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,13 +4,9 @@ on: workflow_dispatch: inputs: target: - description: "Build target (e.g. aarch64)" + description: "Build target (e.g. aarch64 or aarch64_minimal)" default: "x86_64" type: string - flavor: - description: 'Optional build flavor (e.g. _minimal)' - default: '' - type: string parallel: description: 'Massive parallel build of each image' default: true @@ -32,10 +28,6 @@ on: name: required: true type: string - flavor: - required: false - type: string - default: '' infix_repo: required: false type: string @@ -48,7 +40,6 @@ on: env: NAME: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.name || inputs.name }} TARGET: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.target || inputs.target }} - FLV: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.flavor || inputs.flavor }} INFIX_REPO: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.infix_repo || inputs.infix_repo }} jobs: @@ -96,8 +87,7 @@ jobs: name=${{ env.NAME }} echo "dir=${name}-${target}" >> $GITHUB_OUTPUT echo "tgz=${name}-${target}.tar.gz" >> $GITHUB_OUTPUT - echo "flv=$FLV" >> $GITHUB_OUTPUT - echo "Building target ${target}${FLV}_defconfig" + echo "Building target ${target}_defconfig" - name: Restore Cache of dl/ uses: actions/cache@v4 @@ -116,9 +106,9 @@ jobs: ccache-${{ env.TARGET }}- ccache- - - name: Configure ${{ env.TARGET }}${{ steps.vars.outputs.flv }} + - name: Configure ${{ env.TARGET }} run: | - make ${{ env.TARGET }}${{ steps.vars.outputs.flv }}_defconfig + make ${{ env.TARGET }}_defconfig - name: Unit Test ${{ env.TARGET }} run: | @@ -138,9 +128,9 @@ jobs: fi echo "MAKE=$MAKE" >> $GITHUB_OUTPUT - - name: Build ${{ env.TARGET }}${{ steps.vars.outputs.flv }} + - name: Build ${{ env.TARGET }} run: | - echo "Building ${{ env.TARGET }}${{ steps.vars.outputs.flv }}_defconfig ..." + echo "Building ${{ env.TARGET }}_defconfig ..." eval "${{ steps.parallel.outputs.MAKE }}" - name: Check SBOM from Build diff --git a/.github/workflows/generic-x86-build.yml b/.github/workflows/generic-x86-build.yml index 3272d52ab..3a624f460 100644 --- a/.github/workflows/generic-x86-build.yml +++ b/.github/workflows/generic-x86-build.yml @@ -35,7 +35,6 @@ jobs: echo "INFIX_BUILD_ID=${{ github.run_id }}" >> $GITHUB_OUTPUT echo "dir=Infix-x86_64" >> $GITHUB_OUTPUT echo "tgz=Infix-x86_64.tar.gz" >> $GITHUB_OUTPUT - echo "flv=_minimal" >> $GITHUB_OUTPUT - name: Configure x86_64_minimal run: | diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 353fef698..c15d94861 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -25,6 +25,7 @@ jobs: - uses: ncipollo/release-action@v1 with: allowUpdates: true + replacesArtifacts: true omitName: true omitBody: true omitBodyDuringUpdate: true diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ef221f6cc..f63827ed9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -17,10 +17,6 @@ on: name: required: true type: string - flavor: - required: false - type: string - default: '' infix_repo: required: false type: string @@ -35,14 +31,14 @@ on: default: 'test' env: - FLV: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.flavor || inputs.flavor }} + TARGET: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.target || inputs.target }} INFIX_REPO: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.infix_repo || inputs.infix_repo }} NINEPM_CONF: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.ninepm-conf || inputs.ninepm-conf }} TEST_PATH: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.test-path || inputs.test-path }} jobs: test: - name: Regression Test ${{ inputs.name }} ${{ inputs.target }} + name: Regression Test ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.name || inputs.name }} ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.target || inputs.target }} runs-on: [ self-hosted, regression ] steps: - name: Checkout infix repo @@ -62,20 +58,18 @@ jobs: >>$GITHUB_ENV fi - echo "flv=$FLV" >> $GITHUB_OUTPUT - - - name: Configure ${{ inputs.target }}${{ steps.vars.outputs.flv }} + - name: Configure ${{ env.TARGET }} run: | - make ${{ inputs.target }}${{ steps.vars.outputs.flv }}_defconfig + make ${{ env.TARGET }}_defconfig - uses: actions/download-artifact@v4 with: pattern: "artifact-*" merge-multiple: true - - name: Restore x86-64${{ steps.vars.outputs.flv }} output/ + - name: Restore ${{ env.TARGET }} output/ run: | - target=${{ inputs.target }} + target=${{ env.TARGET }} name=${{ inputs.name }} ls -l @@ -85,7 +79,7 @@ jobs: tar xf ${name}-${target}.tar.gz ln -s ${name}-${target} images - - name: Regression Test x86_64${{ steps.vars.outputs.flv }} + - name: Regression Test ${{ env.TARGET }} run: | if [ -n "$NINEPM_CONF" ]; then export NINEPM_PROJ_CONFIG="${GITHUB_WORKSPACE}/$NINEPM_CONF" @@ -93,12 +87,12 @@ jobs: fi make test - - name: Publish Test Result for x86_64${{ steps.vars.outputs.flv }} + - name: Publish Test Result for ${{ env.TARGET }} # Ensure this runs even if Regression Test fails if: always() run: cat $TEST_PATH/.log/last/result-gh.md >> $GITHUB_STEP_SUMMARY - - name: Generate Test Report for x86_64${{ steps.vars.outputs.flv }} + - name: Generate Test Report for ${{ env.TARGET }} # Ensure this runs even if Regression Test fails if: always() run: | diff --git a/.github/workflows/trigger.yml b/.github/workflows/trigger.yml index 8fe5d0ba7..819e0b09a 100644 --- a/.github/workflows/trigger.yml +++ b/.github/workflows/trigger.yml @@ -14,28 +14,25 @@ jobs: if: startsWith(github.repository, 'kernelkit/') uses: ./.github/workflows/build.yml with: - target: "x86_64" name: "infix" - flavor: "_minimal" + target: ${{ (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'ci:main')) && 'x86_64' || 'x86_64_minimal' }} build-aarch64: if: startsWith(github.repository, 'kernelkit/') uses: ./.github/workflows/build.yml with: - target: "aarch64" name: "infix" - flavor: "_minimal" + target: ${{ (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'ci:main')) && 'aarch64' || 'aarch64_minimal' }} test-run-x86_64: if: startsWith(github.repository, 'kernelkit/') needs: build-x86_64 uses: ./.github/workflows/test.yml with: - target: "x86_64" + target: ${{ (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'ci:main')) && 'x86_64' || 'x86_64_minimal' }} name: "infix" test-publish-x86_64: if: startsWith(github.repository, 'kernelkit/') needs: test-run-x86_64 uses: ./.github/workflows/publish.yml -