From c9941c953b70cc8ee313a202094993112ae1d843 Mon Sep 17 00:00:00 2001 From: Eoghan Russell Date: Tue, 27 Feb 2024 14:53:57 +0000 Subject: [PATCH] Add new build test action Signed-off-by: Eoghan Russell --- .github/workflows/buildtest.yml | 36 +++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/buildtest.yml diff --git a/.github/workflows/buildtest.yml b/.github/workflows/buildtest.yml new file mode 100644 index 00000000..b11c3595 --- /dev/null +++ b/.github/workflows/buildtest.yml @@ -0,0 +1,36 @@ +name: Go-build-and-test + +on: + push: + pull_request: + schedule: + - cron: "0 8 * * 0" # every sunday + +jobs: + build-test: + strategy: + matrix: + go-version: [1.21.x] + os: [ubuntu-latest] + goos: [linux] + goarch: [amd64, arm64] + subproject: [ipu-plugin, ipu-device-plugin] # Add more subprojects as needed + runs-on: ${{ matrix.os }} + env: + GO111MODULE: on + steps: + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: ${{ matrix.go-version }} + + - name: Check out code into the Go module directory + uses: actions/checkout@v3 + + - name: Build each subproject + run: | + for subproject in ${{ matrix.subproject }}; do + cd "$subproject" + make + cd .. + done