Skip to content

Commit

Permalink
add GitHub Actions (#293)
Browse files Browse the repository at this point in the history
  • Loading branch information
d5 authored May 23, 2020
1 parent 4ed7576 commit d08a636
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 48 deletions.
47 changes: 0 additions & 47 deletions .circleci/config.yml

This file was deleted.

24 changes: 24 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: release
on:
push:
tags:
- '*'
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- name: check out
uses: actions/checkout@v2
- name: Unshallow
run: git fetch --prune --unshallow
- name: set up Go
uses: actions/setup-go@v2
with:
go-version: 1.14
- name: run goreleaser
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34 changes: 34 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
name: build
runs-on: ubuntu-latest
steps:
- name: set up Go
uses: actions/setup-go@v1
with:
go-version: 1.14
id: go
- name: set up Go module cache
uses: actions/cache@v1
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: setup env
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- name: check out code
uses: actions/checkout@v2
- name: install golint
run: go get -u golang.org/x/lint/golint
- name: run tests
run: make test
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# The Tengo Language

[![GoDoc](https://godoc.org/github.com/d5/tengo?status.svg)](https://godoc.org/github.com/d5/tengo)
![test](https://github.com/d5/tengo/workflows/test/badge.svg)
[![Go Report Card](https://goreportcard.com/badge/github.com/d5/tengo)](https://goreportcard.com/report/github.com/d5/tengo)
[![CircleCI](https://circleci.com/gh/d5/tengo.svg?style=svg)](https://circleci.com/gh/d5/tengo)

**Tengo is a small, dynamic, fast, secure script language for Go.**

Expand Down

0 comments on commit d08a636

Please sign in to comment.