diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index 8c02efb..0000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,30 +0,0 @@ -# Golang CircleCI 2.0 configuration file -# -# Check https://circleci.com/docs/2.0/language-go/ for more details -version: 2 -jobs: - build: - docker: - # specify the version - - image: circleci/golang:1.8 - - # Specify service dependencies here if necessary - # CircleCI maintains a library of pre-built images - # documented at https://circleci.com/docs/2.0/circleci-images/ - # - image: circleci/postgres:9.4 - - #### TEMPLATE_NOTE: go expects specific checkout path representing url - #### expecting it in the form of - #### /go/src/github.com/circleci/go-tool - #### /go/src/bitbucket.org/circleci/go-tool - working_directory: /go/src/github.com/go-xorm/builder - steps: - - checkout - - # specify any bash command here prefixed with `run: ` - - run: go get -u github.com/golang/lint/golint - - run: go get -u github.com/stretchr/testify/assert - - run: go get -u github.com/go-xorm/sqlfiddle - - run: golint ./... - - run: go test -v -race -coverprofile=coverage.txt -covermode=atomic - - run: bash <(curl -s https://codecov.io/bash) \ No newline at end of file diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..ca40377 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,37 @@ +workspace: + base: /go + path: src/github.com/go-xorm/builder + +clone: + git: + image: plugins/git:next + depth: 50 + tags: true + +matrix: + GO_VERSION: + - 1.8 + - 1.9 + - 1.10 + - 1.11 + +pipeline: + test: + image: golang:${GO_VERSION} + commands: + - go get -u github.com/golang/lint/golint + - go get -u github.com/stretchr/testify/assert + - go get -u github.com/go-xorm/sqlfiddle + - golint ./... + - go test -v -race -coverprofile=coverage.txt -covermode=atomic + when: + event: [ push, tag, pull_request ] + +codecov: + image: robertstettner/drone-codecov + group: build + secrets: [ codecov_token ] + files: + - coverage.txt + when: + event: [ push, pull_request ] \ No newline at end of file diff --git a/README.md b/README.md index a7d677d..cf516d1 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # SQL builder -[![CircleCI](https://circleci.com/gh/go-xorm/builder/tree/master.svg?style=svg)](https://circleci.com/gh/go-xorm/builder/tree/master) [![codecov](https://codecov.io/gh/go-xorm/builder/branch/master/graph/badge.svg)](https://codecov.io/gh/go-xorm/builder) +[![GitCI.cn](https://gitci.cn/api/badges/go-xorm/builder/status.svg)](https://gitci.cn/go-xorm/builder) [![codecov](https://codecov.io/gh/go-xorm/builder/branch/master/graph/badge.svg)](https://codecov.io/gh/go-xorm/builder) [![](https://goreportcard.com/badge/github.com/go-xorm/builder)](https://goreportcard.com/report/github.com/go-xorm/builder) Package builder is a lightweight and fast SQL builder for Go and XORM.