diff --git a/.drone.yml b/.drone.yml deleted file mode 100644 index 0252a86..0000000 --- a/.drone.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- -kind: pipeline -type: docker -name: default - -steps: -- name: test - image: golang - commands: - - go test -cover ./... - - go install honnef.co/go/tools/cmd/staticcheck@latest - - "`go env GOPATH`/bin/staticcheck ./..." - -trigger: - event: - include: - - push - - pull_request ---- -hmac: "3578aa331afc59fb761a53431e3886221fae525ada6b31ddcba805d81bb73236" -kind: signature -... diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..292408d --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,27 @@ +name: ci + +on: + pull_request: + push: + branches: + - main + +jobs: + test: + runs-on: ubuntu-latest + container: + image: golang + steps: + - name: Check out source code + uses: actions/checkout@v4 + + - name: Run go test + run: go test -cover ./... + + - name: Install staticcheck + run: go install honnef.co/go/tools/cmd/staticcheck@latest + + - name: Run staticcheck + run: | + chown -R root:root . + staticcheck ./...