Skip to content

Commit

Permalink
move workflows to standalone files (#116)
Browse files Browse the repository at this point in the history
* moves CI to individual files (WIP: path based actions)

* enable conditional paths for workflows
  • Loading branch information
Reecepbcups authored Oct 10, 2023
1 parent b1b6db8 commit 721dea9
Show file tree
Hide file tree
Showing 5 changed files with 124 additions and 39 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/async-icq.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: async-icq
on:
pull_request:
paths:
- 'modules/async-icq/**'
- '.github/workflows/async-icq.yml'

env:
LINT_VERSION: v1.52
GO_VERSION: 1.21.0
WORKING_DIRECTORY: modules/async-icq/

jobs:
golangci:
name: Linter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: ${{ env.LINT_VERSION }}
working-directory: ${{ env.WORKING_DIRECTORY }}
args: --timeout=5m

test:
runs-on: ubuntu-latest
name: test
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: ${{ env.GO_VERSION }}

- uses: actions/checkout@v4

- name: Test
run: go test ./...
working-directory: ${{ env.WORKING_DIRECTORY }}

# TODO: e2e
30 changes: 0 additions & 30 deletions .github/workflows/golangci-lint.yaml

This file was deleted.

40 changes: 40 additions & 0 deletions .github/workflows/ibc-hooks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: ibc-hooks
on:
pull_request:
paths:
- 'modules/ibc-hooks/**'
- '.github/workflows/ibc-hooks.yml'

env:
LINT_VERSION: v1.52
GO_VERSION: 1.21.0
WORKING_DIRECTORY: modules/ibc-hooks/

jobs:
golangci:
name: Linter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: ${{ env.LINT_VERSION }}
working-directory: ${{ env.WORKING_DIRECTORY }}
args: --timeout=5m

test:
runs-on: ubuntu-latest
name: test
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: ${{ env.GO_VERSION }}

- uses: actions/checkout@v4

- name: Test
run: go test ./...
working-directory: ${{ env.WORKING_DIRECTORY }}
42 changes: 42 additions & 0 deletions .github/workflows/packet-forward-middleware.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: packet-forward-middleware
on:
pull_request:
paths:
- 'middleware/packet-forward-middleware/**'
- '.github/workflows/packet-forward-middleware.yml'

env:
LINT_VERSION: v1.52
GO_VERSION: 1.21.0
WORKING_DIRECTORY: middleware/packet-forward-middleware/

jobs:
golangci:
name: Linter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: ${{ env.LINT_VERSION }}
working-directory: ${{ env.WORKING_DIRECTORY }}
args: --timeout=5m

test:
runs-on: ubuntu-latest
name: test
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: ${{ env.GO_VERSION }}

- uses: actions/checkout@v4

- name: Test
run: go test ./...
working-directory: ${{ env.WORKING_DIRECTORY }}

# TODO: e2e
9 changes: 0 additions & 9 deletions tools/resolve-modules.sh

This file was deleted.

0 comments on commit 721dea9

Please sign in to comment.