From 38b2ef596636613076fae99a52e175c9572e5201 Mon Sep 17 00:00:00 2001 From: Gabriel Adrian Samfira Date: Fri, 20 Jan 2023 22:26:52 +0200 Subject: [PATCH] Add linters workflow Signed-off-by: Gabriel Adrian Samfira --- .github/workflows/go-tests.yml | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/.github/workflows/go-tests.yml b/.github/workflows/go-tests.yml index 1ed634be..5501478e 100644 --- a/.github/workflows/go-tests.yml +++ b/.github/workflows/go-tests.yml @@ -9,9 +9,32 @@ on: - main jobs: + linters: + name: Linters + runs-on: ubuntu-20.04 + timeout-minutes: 10 + + steps: + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y libbtrfs-dev + + - uses: actions/setup-go@v3 + - uses: actions/checkout@v3 + - uses: golangci/golangci-lint-action@v3 + with: + version: v1.49.0 + skip-cache: true + args: --timeout=8m --build-tags testing + - name: Verify go vendor and go modules + run: | + sudo apt-get install -y jq + make verify-vendor + go-tests: runs-on: ubuntu-latest - + needs: [linters] steps: - name: Checkout uses: actions/checkout@v3