Skip to content

Update readme

Update readme #106

Workflow file for this run

on: [push, pull_request]
name: CI
jobs:
build-test-lint:
runs-on: ubuntu-latest
steps:
# Prepare
- name: Install Go 1.13
uses: actions/setup-go@v1
with:
go-version: 1.13
- name: Checkout repository
uses: actions/checkout@v2
- name: Export GOPATH
run: echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV
- name: Append GOPATH onto PATH
run: echo "$GOPATH/bin" >> $GITHUB_PATH
# BUILD
# Build all
- name: Build
env:
GOPROXY: "https://proxy.golang.org"
run: go build
# TESTS
# Run all tests
- name: Test
run: go test ./...
# TEST COVERAGE
# Install tools/cmd/cover
- name: Install tools/cmd/cover
run: go get golang.org/x/tools/cmd/cover
# Install overalls
- name: Install overalls
run: go get github.com/go-playground/overalls
# Overalls
- name: overalls
run: overalls -project /home/runner/work/deep-copy/deep-copy -covermode atomic -debug -- -race -v -coverpkg ./...
# Install goveralls
- name: Install goveralls
run: go get github.com/mattn/goveralls
# Goveralls
- name: goveralls
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: goveralls -coverprofile overalls.coverprofile -service=github -repotoken=$COVERALLS_TOKEN
# Codecov
- name: Codecov
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
run: |
cp overalls.coverprofile coverage.txt
bash <(curl -s https://codecov.io/bash)
# LINT
# Install golint
- name: Install golint
run: go get golang.org/x/lint/golint
# Install golangci-lint
- name: Install golangci-lint
run: curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $GOPATH/bin v1.23.6
# go vet
- name: go vet
continue-on-error: true
run: go vet ./...
# golangci-lint
- name: golangci-lint
continue-on-error: true
run: golangci-lint run ./...
# golint
- name: golint
continue-on-error: true
run: golint -set_exit_status $(go list ./...)