Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,53 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-go@v5
- uses: moonrepo/setup-rust@v1
with:
components: rustfmt, clippy
- uses: pre-commit/[email protected]
with:
extra_args: --all-files

tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
submodules: true
- uses: moonrepo/setup-rust@v1
- run: |
cd go-runner
cargo test --all


compat-integration-test-walltime:
runs-on: codspeed-macro
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-go@v5
- uses: moonrepo/setup-rust@v1
with:
cache-target: release

- name: Run the benchmarks
uses: CodSpeedHQ/action@main
with:
working-directory: example
run: cargo r --manifest-path ../go-runner/Cargo.toml -- test -bench=.

check:
runs-on: ubuntu-latest
if: always()
needs:
- lint
- tests
- compat-integration-test-walltime
steps:
- uses: re-actors/alls-green@release/v1
with:
Expand Down
24 changes: 24 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[submodule "go-runner/testdata/projects/fzf"]
path = go-runner/testdata/projects/fzf
url = https://github.com/junegunn/fzf
[submodule "go-runner/testdata/projects/opentelemetry-go"]
path = go-runner/testdata/projects/opentelemetry-go
url = https://github.com/open-telemetry/opentelemetry-go.git
[submodule "go-runner/testdata/projects/golang-benchmarks"]
path = go-runner/testdata/projects/golang-benchmarks
url = https://github.com/SimonWaldherr/golang-benchmarks
[submodule "go-runner/testdata/projects/fuego"]
path = go-runner/testdata/projects/fuego
url = https://github.com/go-fuego/fuego
[submodule "go-runner/testdata/projects/hugo"]
path = go-runner/testdata/projects/hugo
url = https://github.com/gohugoio/hugo.git
[submodule "go-runner/testdata/projects/zerolog"]
path = go-runner/testdata/projects/zerolog
url = https://github.com/rs/zerolog
[submodule "go-runner/testdata/projects/zap"]
path = go-runner/testdata/projects/zap
url = https://github.com/uber-go/zap
[submodule "go-runner/testdata/projects/cli-runtime"]
path = go-runner/testdata/projects/cli-runtime
url = https://github.com/kubernetes/cli-runtime.git
29 changes: 29 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ repos:
- id: end-of-file-fixer
- id: check-yaml
- id: check-json
exclude: ^go-runner/testdata/
- id: check-merge-conflict
- id: check-added-large-files

Expand All @@ -14,3 +15,31 @@ repos:
hooks:
- id: go-mod-tidy
- id: go-fmt
exclude: ^go-runner/src/builder/template\.go$

- repo: https://github.com/doublify/pre-commit-rust
rev: v1.0
hooks:
- id: fmt
args: [--all, --]
files: ^go-runner/
pass_filenames: false
additional_dependencies: []
entry: bash -c 'cd go-runner && cargo fmt --all'
language: system

- id: cargo-check
args: [--all-targets]
files: ^go-runner/
pass_filenames: false
additional_dependencies: []
entry: bash -c 'cd go-runner && cargo check --all-targets'
language: system

- id: clippy
args: [--all-targets, --, -D, warnings]
files: ^go-runner/
pass_filenames: false
additional_dependencies: []
entry: bash -c 'cd go-runner && cargo clippy --all-targets -- -D warnings'
language: system
3 changes: 3 additions & 0 deletions go-runner/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
build-*/
target/
.codspeed
Loading
Loading