Takeru Ohta 3 лет назад
Родитель
Сommit
9a6b8ef659
3 измененных файлов с 34 добавлено и 24 удалено
  1. 33 0
      .github/workflows/ci.yml
  2. 0 23
      .travis.yml
  3. 1 1
      README.md

+ 33 - 0
.github/workflows/ci.yml

@@ -0,0 +1,33 @@
+---
+name: build
+on:
+  push:
+    branches:
+      - master
+  pull_request:
+    branches:
+      - master
+jobs:
+  ci:
+    name: Run checks and tests over ${{matrix.otp_vsn}} and ${{matrix.os}}
+    runs-on: ${{matrix.os}}
+    strategy:
+      matrix:
+        otp_vsn: [19.3, 20.0, 21.0, 22.0, 23.0, 24.0]
+        os: [ubuntu-latest]
+    steps:
+      - uses: actions/checkout@v2
+      - run: rebar3 compile
+      - run: rebar3 xref
+      - run: rebar3 eunit
+      - run: rebar3 dialyzer
+      - run: rebar3 edoc
+      - run: rebar3 cover
+      - run: rebar3 as test covertool generate
+      - run: cp _build/test/covertool/jsone.covertool.xml ./cobertura.xml
+  cov:
+    needs: ci
+    runs-on: ubuntu-latest
+    steps:
+      - run: sudo pip install codecov
+      - run: codecov

+ 0 - 23
.travis.yml

@@ -1,23 +0,0 @@
-language: erlang
-
-os: linux
-otp_release:
-  - 22.0
-  - 21.0
-  - 20.0
-  - 19.3
-
-install:
-  - sudo pip install codecov
-script:
-  - rebar3 compile
-  - rebar3 xref
-  - rebar3 eunit
-  - rebar3 dialyzer
-  - rebar3 edoc
-  - rebar3 cover
-  - rebar3 as test covertool generate
-  - cp _build/test/covertool/jsone.covertool.xml ./cobertura.xml
-
-after_success:
-  - codecov

+ 1 - 1
README.md

@@ -2,7 +2,7 @@ jsone
 =====
 
 [![hex.pm version](https://img.shields.io/hexpm/v/jsone.svg)](https://hex.pm/packages/jsone)
-[![Build Status](https://travis-ci.org/sile/jsone.svg?branch=master)](https://travis-ci.org/sile/jsone)
+[![Build Status](https://github.com/sile/jsone/workflows/build/badge.svg)](https://github.com/sile/jsone)
 [![Code Coverage](https://codecov.io/gh/sile/jsone/branch/master/graph/badge.svg)](https://codecov.io/gh/sile/jsone/branch/master)
 [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)