parent
9957380b6d
commit
2b13b3f128
28
.github/workflows/build.yml
vendored
28
.github/workflows/build.yml
vendored
@ -1,6 +1,6 @@
|
|||||||
name: build
|
name: build
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
jobs:
|
jobs:
|
||||||
@ -12,20 +12,36 @@ jobs:
|
|||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v2
|
||||||
with:
|
with:
|
||||||
go-version: 1.16
|
go-version: 1.16
|
||||||
- name: checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: cache
|
- name: cache
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
path: ~/go/pkg/mod
|
path: ~/go/pkg/mod
|
||||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: ${{ runner.os }}-go-
|
restore-keys: ${{ runner.os }}-go-
|
||||||
- name: deps
|
- name: sdk checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: sdk deps
|
||||||
run: go get -v -t -d ./...
|
run: go get -v -t -d ./...
|
||||||
- name: test
|
- name: sdk test
|
||||||
env:
|
env:
|
||||||
INTEGRATION_TESTS: yes
|
INTEGRATION_TESTS: yes
|
||||||
run: go test -mod readonly -v ./...
|
run: go test -mod readonly -v ./...
|
||||||
|
- name: tests checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
repository: unistack-org/micro-tests
|
||||||
|
ref: refs/heads/master
|
||||||
|
path: micro-tests
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: tests deps
|
||||||
|
run: |
|
||||||
|
cd micro-tests
|
||||||
|
go mod edit -replace="github.com/unistack-org/micro/v3=../"
|
||||||
|
go get -v -t -d ./...
|
||||||
|
- name: tests test
|
||||||
|
env:
|
||||||
|
INTEGRATION_TESTS: yes
|
||||||
|
run: cd micro-tests && go test -mod readonly -v ./...
|
||||||
lint:
|
lint:
|
||||||
name: lint
|
name: lint
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -37,7 +53,7 @@ jobs:
|
|||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
with:
|
with:
|
||||||
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
||||||
version: v1.30
|
version: v1.39
|
||||||
# Optional: working directory, useful for monorepos
|
# Optional: working directory, useful for monorepos
|
||||||
# working-directory: somedir
|
# working-directory: somedir
|
||||||
# Optional: golangci-lint command line arguments.
|
# Optional: golangci-lint command line arguments.
|
||||||
|
4
.github/workflows/codeql-analysis.yml
vendored
4
.github/workflows/codeql-analysis.yml
vendored
@ -12,10 +12,6 @@
|
|||||||
name: "CodeQL"
|
name: "CodeQL"
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_run:
|
|
||||||
workflows: ["prbuild"]
|
|
||||||
types:
|
|
||||||
- completed
|
|
||||||
push:
|
push:
|
||||||
branches: [ master ]
|
branches: [ master ]
|
||||||
pull_request:
|
pull_request:
|
||||||
|
3
.github/workflows/dependabot-automerge.yml
vendored
3
.github/workflows/dependabot-automerge.yml
vendored
@ -15,7 +15,6 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
# Contains workaround to execute if dependabot updates the PR by checking for the base branch in the linked PR
|
# Contains workaround to execute if dependabot updates the PR by checking for the base branch in the linked PR
|
||||||
# The the github.event.workflow_run.event value is 'push' and not 'pull_request'
|
# The the github.event.workflow_run.event value is 'push' and not 'pull_request'
|
||||||
# dont work with multiple workflows when last returns success
|
|
||||||
if: >-
|
if: >-
|
||||||
github.event.workflow_run.conclusion == 'success'
|
github.event.workflow_run.conclusion == 'success'
|
||||||
&& github.actor == 'dependabot[bot]'
|
&& github.actor == 'dependabot[bot]'
|
||||||
@ -24,8 +23,6 @@ jobs:
|
|||||||
&& (github.event.workflow_run.event == 'pull_request'
|
&& (github.event.workflow_run.event == 'pull_request'
|
||||||
|| (github.event.workflow_run.event == 'push' && github.event.workflow_run.pull_requests[0].base.ref == github.event.repository.default_branch ))
|
|| (github.event.workflow_run.event == 'push' && github.event.workflow_run.pull_requests[0].base.ref == github.event.repository.default_branch ))
|
||||||
steps:
|
steps:
|
||||||
- name: Wait workflows success
|
|
||||||
uses: ahmadnassri/action-workflow-run-wait@v1
|
|
||||||
- name: Approve Changes and Merge changes if label 'dependencies' is set
|
- name: Approve Changes and Merge changes if label 'dependencies' is set
|
||||||
uses: actions/github-script@v4
|
uses: actions/github-script@v4
|
||||||
with:
|
with:
|
||||||
|
28
.github/workflows/pr.yml
vendored
28
.github/workflows/pr.yml
vendored
@ -12,20 +12,36 @@ jobs:
|
|||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v2
|
||||||
with:
|
with:
|
||||||
go-version: 1.16
|
go-version: 1.16
|
||||||
- name: checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: cache
|
- name: cache
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
path: ~/go/pkg/mod
|
path: ~/go/pkg
|
||||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: ${{ runner.os }}-go-
|
restore-keys: ${{ runner.os }}-go-
|
||||||
- name: deps
|
- name: sdk checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: sdk deps
|
||||||
run: go get -v -t -d ./...
|
run: go get -v -t -d ./...
|
||||||
- name: test
|
- name: sdk test
|
||||||
env:
|
env:
|
||||||
INTEGRATION_TESTS: yes
|
INTEGRATION_TESTS: yes
|
||||||
run: go test -mod readonly -v ./...
|
run: go test -mod readonly -v ./...
|
||||||
|
- name: tests checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
repository: unistack-org/micro-tests
|
||||||
|
ref: refs/heads/master
|
||||||
|
path: micro-tests
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: tests deps
|
||||||
|
run: |
|
||||||
|
cd micro-tests
|
||||||
|
go mod edit -replace="github.com/unistack-org/micro/v3=../"
|
||||||
|
go get -v -t -d ./...
|
||||||
|
- name: tests test
|
||||||
|
env:
|
||||||
|
INTEGRATION_TESTS: yes
|
||||||
|
run: cd micro-tests && go test -mod readonly -v ./...
|
||||||
lint:
|
lint:
|
||||||
name: lint
|
name: lint
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -37,7 +53,7 @@ jobs:
|
|||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
with:
|
with:
|
||||||
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
||||||
version: v1.30
|
version: v1.39
|
||||||
# Optional: working directory, useful for monorepos
|
# Optional: working directory, useful for monorepos
|
||||||
# working-directory: somedir
|
# working-directory: somedir
|
||||||
# Optional: golangci-lint command line arguments.
|
# Optional: golangci-lint command line arguments.
|
||||||
|
Loading…
Reference in New Issue
Block a user