Skip to content

Commit

Permalink
Update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
mattiaswal committed Feb 20, 2025
1 parent 6f54710 commit cac03ab
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 38 deletions.
49 changes: 11 additions & 38 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@ on:
branches:
- main
workflow_dispatch:
inputs:
minimal:
description: 'Build minimal defconfigs'
required: false
default: true
type: boolean

jobs:
build:
Expand Down Expand Up @@ -50,21 +44,7 @@ jobs:
"${{ github.event.number }}" "${{ github.event.pull_request.head.sha }}" \
| tee -a $GITHUB_OUTPUT $GITHUB_ENV
fi
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
if [ "${{ github.event.inputs.minimal }}" == "true" ]; then
flavor="_minimal"
fi
else
# Ensure 'release' job get the proper image when building main
if [ "$GITHUB_REF_NAME" != "main" ]; then
flavor="_minimal"
else
flavor=""
fi
if ${{ contains(github.event.pull_request.labels.*.name, 'ci:main') }}; then
flavor=""
fi
fi
target=${{ matrix.target }}
echo "dir=vendor-example-$target" >> $GITHUB_OUTPUT
echo "tgz=vendor-example-$target.tar.gz" >> $GITHUB_OUTPUT
Expand All @@ -87,17 +67,17 @@ jobs:
ccache-${{ matrix.target }}-
ccache-
- name: Configure ${{ matrix.target }}${{ steps.vars.outputs.flv }}
- name: Configure ${{ matrix.target }}
run: |
make ${{ matrix.target }}${{ steps.vars.outputs.flv }}_defconfig
make ${{ matrix.target }}_defconfig
- name: Unit Test ${{ matrix.target }}
run: |
make test-unit
- name: Build ${{ matrix.target }}${{ steps.vars.outputs.flv }}
- name: Build ${{ matrix.target }}
run: |
echo "Building ${{ matrix.target }}${{ steps.vars.outputs.flv }}_defconfig ..."
echo "Building ${{ matrix.target }}_defconfig ..."
make
- name: Check SBOM from Build
Expand Down Expand Up @@ -149,23 +129,16 @@ jobs:
>>$GITHUB_ENV
fi
if [ "$GITHUB_REF_NAME" != "main" ]; then
flavor="_minimal"
else
flavor=""
fi
echo "flv=$flavor" >> $GITHUB_OUTPUT
- name: Configure x86_64${{ steps.vars.outputs.flv }}
- name: Configure x86_64
run: |
make x86_64${{ steps.vars.outputs.flv }}_defconfig
make x86_64_defconfig
- uses: actions/download-artifact@v4
with:
pattern: "artifact-*"
merge-multiple: true

- name: Restore x86-64${{ steps.vars.outputs.flv }} output/
- name: Restore x86-64 output/
run: |
ls -l
mkdir -p output
Expand All @@ -174,16 +147,16 @@ jobs:
tar xf vendor-example-x86_64.tar.gz
ln -s vendor-example-x86_64 images
- name: Regression Test x86_64${{ steps.vars.outputs.flv }}
- name: Regression Test x86_64
run: |
make test
- name: Publish Test Result for x86_64${{ steps.vars.outputs.flv }}
- name: Publish Test Result for x86_64
# Ensure this runs even if Regression Test fails
if: always()
run: cat infix/test/.log/last/result-gh.md >> $GITHUB_STEP_SUMMARY

- name: Generate Test Report for x86_64${{ steps.vars.outputs.flv }}
- name: Generate Test Report for x86_64
# Ensure this runs even if Regression Test fails
if: always()
run: |
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/sync-infix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
fi
cd infix
git fetch --recurse-submodules
git clean -ffdx
git checkout main
git clean -ffdx
Expand Down

0 comments on commit cac03ab

Please sign in to comment.