Open
Description
Context:
We have a repository which has a structure similar to
- root module
-- pkgA submodule
-- pkgB submodule
-- etc...
root
module has no go files.
Each pkg{A,B,...}
module has code+tests and separate go.mod+go.sum+vendor files.
Issue:
On every PR we are running
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-go@v1
with:
go-version: '1.15.x'
- name: Run tests
# Go into each folder in the repo and run tests 10 times with the race detector
run: for d in ./*/ ; do (cd "$d" && go test -race -count 10 ./...); done
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install golangci-lint
uses: golangci/golangci-lint-action@v0.2.0
with:
version: v1.26
args: --modules-download-mode vendor --config ./.golangci.yml ./...
But it fails with ERRO Running error: context loading failed: no go files to analyze
Question:
Is there a way to use this action to run linter in all the folders but without creating separate jobs with a matrix?