github.com/hslam/atomic@v1.0.0/.github/workflows/go.yml (about)

     1  name: build
     2  
     3  on: [push,pull_request]
     4  
     5  jobs:
     6  
     7    build:
     8      name: Build
     9      runs-on: ubuntu-latest
    10      steps:
    11  
    12      - name: Set up Go 1.x
    13        uses: actions/setup-go@v2
    14        with:
    15          go-version: ^1.15
    16  
    17      - name: Check out code into the Go module directory
    18        uses: actions/checkout@v2
    19  
    20      - name: Get dependencies
    21        run: |
    22          go get -v -t -d ./...
    23          if [ -f Gopkg.toml ]; then
    24              curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
    25              dep ensure
    26          fi
    27      - name: Build
    28        run: go build -v ./...
    29  
    30      - name: Test
    31        run: go test -v ./...
    32  
    33      - name: Bench
    34        run: go test -v -run="none" -bench=.
    35  
    36      - name: Coverage
    37        run: |
    38          go test -coverprofile=coverage.txt -covermode=atomic
    39          bash <(curl -s https://codecov.io/bash)