forked from 0xPolygon/polygon-edge
-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' into hardfork/pos
- Loading branch information
Showing
17 changed files
with
589 additions
and
240 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
--- | ||
name: Build | ||
on: # yamllint disable-line rule:truthy | ||
workflow_dispatch: | ||
workflow_call: | ||
|
||
jobs: | ||
go_build: | ||
name: Dogechain | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Setup Go environment | ||
# uses: actions/setup-go@v3.3.0 | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: 1.17.x | ||
|
||
- name: Build Dogechain | ||
# run: go build -tags netgo -ldflags="-s -w -linkmode external -extldflags "-static" -X \"github.com/dogechain-lab/dogechain/versioning.Version=${GITHUB_REF_NAME}\" -X \"github.com/dogechain-lab/dogechain/versioning.Commit=${GITHUB_SHA}\"" && tar -czvf dogechain.tar.gz dogechain | ||
run: go build -a -o dogechain . && tar -czvf dogechain.tar.gz dogechain | ||
env: | ||
CGO_ENABLED: 0 | ||
CC: gcc | ||
CXX: g++ | ||
GOARC: amd64 | ||
GOOS: linux | ||
|
||
- name: Extract branch name | ||
# if: github.event_name != 'pull_request' | ||
shell: bash | ||
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | ||
id: extract_branch | ||
|
||
- name: "Upload Artifact" | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: dogechain_${{ github.sha }}_${{ steps.extract_branch.outputs.branch }} | ||
path: dogechain.tar.gz | ||
retention-days: 7 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
--- | ||
name: E2E tests | ||
on: # yamllint disable-line rule:truthy | ||
push: | ||
branches: | ||
- main | ||
- dev | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
# env: | ||
# E2E_TESTS: true | ||
# E2E_LOGS: true | ||
# CI_VERBOSE: true | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: 1.17.x | ||
- name: Run tests | ||
run: make test-e2e | ||
# - name: Archive test logs | ||
# if: always() | ||
# uses: actions/upload-artifact@v3 | ||
# with: | ||
# name: e2e-logs | ||
# path: e2e-logs-*/ | ||
# retention-days: 30 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
name: Lint | ||
on: # yamllint disable-line rule:truthy | ||
push: | ||
branches-ignore: | ||
- "main" | ||
- "dev" | ||
tags-ignore: | ||
- "v*" | ||
paths: | ||
- "**.go" | ||
workflow_call: {} | ||
workflow_dispatch: {} | ||
pull_request: | ||
|
||
jobs: | ||
golangci_lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Install Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: 1.17.x | ||
|
||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Lint | ||
uses: golangci/golangci-lint-action@v3 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
name: Test | ||
on: # yamllint disable-line rule:truthy | ||
workflow_dispatch: | ||
workflow_call: | ||
pull_request: | ||
|
||
jobs: | ||
go_test: | ||
name: Dogechain | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Setup Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: 1.17.x | ||
|
||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Run Go Test | ||
run: go test -coverprofile coverage.out -timeout 20m `go list ./... | grep -v e2e` | ||
|
||
- name: Upload coverage file to Codecov | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
files: coverage.out |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.