...

Text file src/github.com/sourcegraph/conc/.github/workflows/go.yml

Documentation: github.com/sourcegraph/conc/.github/workflows

     1# This workflow will build a golang project
     2# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
     3
     4name: Go
     5
     6on:
     7  push:
     8    branches: [ "main" ]
     9  pull_request:
    10    branches: [ "main" ]
    11
    12jobs:
    13
    14  build:
    15    strategy:
    16      matrix:
    17        go-version: ['1.19', 'stable']
    18    runs-on: ubuntu-latest
    19    steps:
    20    - uses: actions/checkout@v3
    21
    22    - name: Set up Go ${{ matrix.go-version }}
    23      uses: actions/setup-go@v3
    24      with:
    25        go-version: ${{ matrix.go-version }}
    26
    27    - name: Build
    28      run: go build -v ./...
    29
    30    - name: Lint
    31      uses: golangci/golangci-lint-action@v3.3.1
    32      with:
    33        version: latest
    34        args: --timeout 5m
    35
    36    - name: Test
    37      run: go test -race -v ./... -coverprofile ./coverage.txt
    38
    39    - name: Codecov
    40      uses: codecov/codecov-action@v3.1.1
    41      with:
    42        files: ./coverage.txt
    43

View as plain text