2019-08-15 02:38:02 -05:00
|
|
|
name: git2go CI
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2020-02-22 17:07:08 -06:00
|
|
|
- release-*
|
2019-08-15 02:38:02 -05:00
|
|
|
- v*
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
2020-02-22 17:07:08 -06:00
|
|
|
build-legacy:
|
2019-08-15 02:38:02 -05:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2020-02-22 17:07:08 -06:00
|
|
|
go: [ '1.9', '1.10' ]
|
2019-08-15 02:38:02 -05:00
|
|
|
name: Go ${{ matrix.go }}
|
|
|
|
|
|
|
|
runs-on: ubuntu-18.04
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Set up Go
|
|
|
|
uses: actions/setup-go@v1
|
|
|
|
with:
|
|
|
|
go-version: ${{ matrix.go }}
|
|
|
|
id: go
|
2020-02-22 17:07:08 -06:00
|
|
|
- name: Check out code into the GOPATH
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
with:
|
|
|
|
fetch-depth: 1
|
|
|
|
path: src/github.com/${{ github.repository }}
|
|
|
|
- name: Build
|
|
|
|
env:
|
|
|
|
GOPATH: /home/runner/work/git2go
|
|
|
|
run: |
|
|
|
|
git submodule update --init
|
|
|
|
make build-libgit2-static
|
2020-06-20 18:24:46 -05:00
|
|
|
go get -tags static github.com/${{ github.repository }}/...
|
|
|
|
go build -tags static github.com/${{ github.repository }}/...
|
2020-02-22 17:07:08 -06:00
|
|
|
- name: Test
|
|
|
|
env:
|
|
|
|
GOPATH: /home/runner/work/git2go
|
|
|
|
run: make test-static
|
|
|
|
|
|
|
|
build-static:
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
go: [ '1.11', '1.12', '1.13' ]
|
|
|
|
name: Go ${{ matrix.go }}
|
|
|
|
|
|
|
|
runs-on: ubuntu-18.04
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Set up Go
|
|
|
|
uses: actions/setup-go@v1
|
|
|
|
with:
|
|
|
|
go-version: ${{ matrix.go }}
|
|
|
|
id: go
|
|
|
|
- name: Check out code into the Go module directory
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: Build
|
|
|
|
run: |
|
|
|
|
git submodule update --init
|
|
|
|
make build-libgit2-static
|
|
|
|
- name: Test
|
|
|
|
run: make test-static
|
|
|
|
|
|
|
|
build-dynamic:
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
name: Go (dynamic)
|
|
|
|
|
|
|
|
runs-on: ubuntu-18.04
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Set up Go
|
|
|
|
uses: actions/setup-go@v1
|
|
|
|
with:
|
|
|
|
go-version: '1.13'
|
|
|
|
id: go
|
2019-08-15 02:38:02 -05:00
|
|
|
- name: Check out code into the Go module directory
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: Build
|
2019-08-15 02:42:58 -05:00
|
|
|
run: |
|
|
|
|
git submodule update --init
|
2020-02-22 17:07:08 -06:00
|
|
|
make build-libgit2-dynamic
|
|
|
|
- name: Test
|
|
|
|
run: make test-dynamic
|