-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* refactor & testing * testing * update gitignore
- Loading branch information
Showing
11 changed files
with
86,955 additions
and
196 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,19 @@ | ||
version: 2 | ||
|
||
updates: | ||
|
||
# Maintain dependencies for GitHub Actions | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" | ||
assignees: | ||
- "mikenye" | ||
|
||
# Maintain dependencies for pw-feeder go modules | ||
- package-ecosystem: "gomod" | ||
directory: "/pw-feeder" | ||
schedule: | ||
interval: "daily" | ||
assignees: | ||
- "mikenye" |
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,50 @@ | ||
--- | ||
name: Upload Release Asset | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
codecov: | ||
runs-on: ubuntu-latest | ||
name: Codecov | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: 'stable' | ||
- name: "go mod tidy" | ||
run: | | ||
go mod tidy | ||
- name: "go test" | ||
run: | | ||
go test -v -failfast -timeout=300s -count=2 -coverprofile=coverage.txt ./... | ||
- name: Upload coverage reports to Codecov | ||
uses: codecov/codecov-action@v3 | ||
|
||
upload: | ||
needs: codecov | ||
strategy: | ||
matrix: | ||
os: [linux] | ||
arch: [amd64,arm64] | ||
name: Upload | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: 'stable' | ||
- name: "go mod tidy" | ||
run: | | ||
go mod tidy | ||
- name: "go build" | ||
run: | | ||
GOOS=${{ matrix.os }} GOARCH=${{ matrix.arch }} go build ./cmd/sbsmux | ||
tar cJvf ../sbsmux.${{ github.ref_name }}.${{ matrix.os }}.${{ matrix.arch }}.tar.xz ./sbsmux | ||
rm -v ./sbsmux | ||
- name: Upload binaries to release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
gh release upload ${{ github.ref_name }} ./sbsmux.${{ github.ref_name }}.${{ matrix.os }}.${{ matrix.arch }}.tar.xz |
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,56 @@ | ||
--- | ||
name: Pull Request | ||
|
||
on: | ||
# Enable manual running of action if necessary | ||
workflow_dispatch: | ||
# Test build/deploy on PRs to main/master | ||
pull_request: | ||
# Only publish on push to main branch | ||
branches: | ||
- main | ||
# Don't trigger if it's just a documentation update | ||
paths-ignore: | ||
- '**.md' | ||
- '**.MD' | ||
- '**.yml' | ||
- '.gitattributes' | ||
- '.gitignore' | ||
push: | ||
# Only publish on push to main branch | ||
branches: | ||
- main | ||
# Don't trigger if it's just a documentation update | ||
paths-ignore: | ||
- '**.md' | ||
- '**.MD' | ||
- '**.yml' | ||
- '.gitattributes' | ||
- '.gitignore' | ||
|
||
jobs: | ||
|
||
tests: | ||
name: Test sbsmux | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: 'stable' | ||
- name: "go mod tidy" | ||
run: | | ||
go mod tidy | ||
- name: "go test" | ||
run: | | ||
go test -v -failfast -timeout=300s -count=2 -coverprofile=coverage.txt ./... | ||
- name: "application testing" | ||
run: | | ||
sudo apt-get update -y | ||
sudo apt-get install pv -y | ||
bash ./test.sh | ||
- name: Upload coverage reports to Codecov | ||
uses: codecov/codecov-action@v3 | ||
- name: "go build" | ||
run: | | ||
go build ./... |
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 |
---|---|---|
@@ -1 +1 @@ | ||
./bin | ||
bin |
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.