Switch to CircleCI (#48)

This commit is contained in:
Tyler Sommer 2021-09-17 21:53:19 -06:00 committed by GitHub
parent 7e30a1300e
commit 887d99ff96
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 49 additions and 25 deletions

44
.circleci/config.yml Normal file
View file

@ -0,0 +1,44 @@
version: 2.1
jobs:
"test":
parameters:
version:
type: string
default: "latest"
docker:
- image: "circleci/golang:<< parameters.version >>"
working_directory: /go/src/github.com/tyler-sommer/stick
environment:
GO111MODULE: "on"
steps:
- checkout
- run:
name: "Print Go version"
command: go version
- run:
name: "Install dependencies"
command: go get -v ./...
- when:
condition:
equal: [ latest, << parameters.version >> ]
steps:
- run:
name: "Run go vet"
command: go vet -v ./...
- run:
name: "Run goimports"
command: |
go install golang.org/x/tools/cmd/goimports@latest
diff -u <(echo -n) <(goimports -d -e .)
- run:
name: "Run go test"
command: go test -v -race ./...
workflows:
tests:
jobs:
- test:
matrix:
parameters:
version: ["latest", "1.17", "1.16", "1.15", "1.14", "1.13", "1.12", "1.11", "1.10", "1.9", "1.8", "1.7"]

View file

@ -1,24 +0,0 @@
language: go
go:
- '1.7'
- '1.8'
- '1.9'
- '1.10'
- '1.11'
- '1.12'
- '1.13'
- '1.14'
- 'tip'
os:
- linux
- osx
env:
- GIMME_ARCH=amd64
matrix:
fast_finish: true
allow_failures:
- go: tip

View file

@ -1,7 +1,7 @@
Stick
=====
[![Build Status](https://travis-ci.org/tyler-sommer/stick.svg?branch=master)](https://travis-ci.org/tyler-sommer/stick)
[![CircleCI](https://circleci.com/gh/tyler-sommer/stick/tree/master.svg?style=shield)](https://circleci.com/gh/tyler-sommer/stick/tree/master)
[![GoDoc](https://godoc.org/github.com/tyler-sommer/stick?status.svg)](https://godoc.org/github.com/tyler-sommer/stick)
A Go language port of the [Twig](http://twig.sensiolabs.org/) templating engine.

View file

@ -1,3 +1,4 @@
//go:build debug
// +build debug
package parse

View file

@ -1,3 +1,4 @@
//go:build !debug
// +build !debug
package parse

View file

@ -1,3 +1,4 @@
//go:build go1.10
// +build go1.10
package filter

View file

@ -1,3 +1,4 @@
//go:build !go1.10
// +build !go1.10
package filter