Skip to content

Commit d8039d0

Browse files
committed
Adds github actions for lint, test, and release workflows
1 parent b6e61fc commit d8039d0

3 files changed

Lines changed: 61 additions & 0 deletions

File tree

.github/workflows/lint.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Run lint and static analyis checks
2+
on:
3+
pull_request:
4+
5+
concurrency:
6+
group: lint-${{ github.head_ref || github.ref }}
7+
cancel-in-progress: true
8+
9+
jobs:
10+
lint:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Clone this git repository
14+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
15+
16+
- name: Install lint dependencies
17+
run: make lint/install
18+
19+
- name: Run lint checks
20+
run: make -o docs/lint lint

.github/workflows/release.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Create GitHub Release
2+
3+
on:
4+
# Run on demand
5+
workflow_dispatch:
6+
7+
# Run on push to main when .bumpversion.cfg version is updated
8+
push:
9+
branches:
10+
- main
11+
- master
12+
paths:
13+
- .bumpversion.cfg
14+
15+
jobs:
16+
release:
17+
uses: plus3it/actions-workflows/.github/workflows/release.yml@00bdf2c02c2bb252dc7ba7f74816ac8359aa6693
18+
secrets:
19+
release-token: ${{ secrets.GH_RELEASES_TOKEN }}

.github/workflows/test.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Run test jobs
2+
on:
3+
pull_request:
4+
5+
concurrency:
6+
group: test-${{ github.head_ref || github.ref }}
7+
cancel-in-progress: true
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
env:
13+
IMAGE_NAME: tardigrade-ci-test
14+
steps:
15+
- name: Clone this git repository
16+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
17+
18+
- name: Build the docker image
19+
run: docker build --quiet --build-arg "GITHUB_ACCESS_TOKEN=${{ secrets.GH_READONLY_TOKEN }}" -t "${{ env.IMAGE_NAME }}" -f Dockerfile .
20+
21+
- name: Run bats tests
22+
run: docker run "${{ env.IMAGE_NAME }}" bats/test

0 commit comments

Comments
 (0)