Skip to content

Commit

Permalink
chore(action): add ci
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin Cui <bh@bugs.cc>
  • Loading branch information
BlackHole1 committed Feb 22, 2024
1 parent c64e720 commit 92ca35f
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,34 +123,33 @@ jobs:
target-arch: ${{ fromJSON(needs.pre-test.outputs.matrix) }}

steps:
# - name: Checkout
# uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

# - name: Update kernel submodules
# if: ${{ startsWith(matrix.target-arch, 'kernel') }}
# run: git submodule update --init kernel
- name: Update kernel submodules
if: ${{ startsWith(matrix.target-arch, 'kernel') }}
run: git submodule update --init kernel

# - name: Update buildroot submodules
# if: ${{ !startsWith(matrix.target-arch, 'kernel') }}
# run: git submodule update --init buildroot
- name: Update buildroot submodules
if: ${{ !startsWith(matrix.target-arch, 'kernel') }}
run: git submodule update --init buildroot

# - name: Install deps
# run: sudo apt-get install -y build-essential flex bison libssl-dev libelf-dev bc
- name: Install deps
run: sudo apt-get install -y build-essential flex bison libssl-dev libelf-dev bc

# - name: Install kernel arm64 deps
# if: ${{ matrix.target-arch == 'kernel-arm64' }}
# run: sudo apt-get install -y gcc-aarch64-linux-gnu
- name: Install kernel arm64 deps
if: ${{ matrix.target-arch == 'kernel-arm64' }}
run: sudo apt-get install -y gcc-aarch64-linux-gnu

# - name: Defconfig
# run: make defconfig-${{ matrix.target-arch }}
- name: Defconfig
run: make defconfig-${{ matrix.target-arch }}

# - name: Build
# run: make build-${{ matrix.target-arch }} -j$(nproc)
- name: Build
run: make build-${{ matrix.target-arch }} -j$(nproc)

- name: Get output file size
run: |
FILE_PATH=/usr/bin/ls
# FILE_PATH=$(make print-outpath-${{ matrix.target-arch }})
FILE_PATH=$(make print-outpath-${{ matrix.target-arch }})
SIZE_B=$(stat -c%s "$FILE_PATH")
SIZE_MB=$(echo $SIZE_B | awk '{ printf "%.4f", $1 / 1024 / 1024 }')
Expand Down

0 comments on commit 92ca35f

Please sign in to comment.