ci: refactor to native change detection (#70)
Removing the 3rd party dependent "check-changes" job, while keeping the "test" job. Replacing the check-changes with GitHub Action's native "paths" parameter. Reviewed-on: #70 Co-authored-by: Timo Behrendt <t.behrendt@t00n.de> Co-committed-by: Timo Behrendt <t.behrendt@t00n.de>
This commit was merged in pull request #70.
This commit is contained in:
@@ -4,33 +4,18 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
paths:
|
||||||
|
- src/**
|
||||||
|
- .bun-version
|
||||||
|
- package.json
|
||||||
|
- tsconfig.json
|
||||||
|
- Dockerfile
|
||||||
|
- bun.lockb
|
||||||
|
|
||||||
env:
|
env:
|
||||||
DOCKER_REGISTRY: gitea.t000-n.de
|
DOCKER_REGISTRY: gitea.t000-n.de
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
check-changes:
|
|
||||||
name: Check changes
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
outputs:
|
|
||||||
changes: ${{ steps.filter.outputs.code }}
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
|
|
||||||
|
|
||||||
- name: Get changed files
|
|
||||||
id: filter
|
|
||||||
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3
|
|
||||||
with:
|
|
||||||
filters: |
|
|
||||||
code:
|
|
||||||
- 'src/**'
|
|
||||||
- '.bun-version'
|
|
||||||
- 'package.json'
|
|
||||||
- 'tsconfig.json'
|
|
||||||
- 'Dockerfile'
|
|
||||||
- 'bun.lockb'
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
name: Test
|
name: Test
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -58,11 +43,9 @@ jobs:
|
|||||||
arch: [amd64, arm64]
|
arch: [amd64, arm64]
|
||||||
needs:
|
needs:
|
||||||
- test
|
- test
|
||||||
- check-changes
|
|
||||||
runs-on:
|
runs-on:
|
||||||
- ubuntu-latest
|
- ubuntu-latest
|
||||||
- linux_${{ matrix.arch }}
|
- linux_${{ matrix.arch }}
|
||||||
if: ${{ needs.check-changes.outputs.changes == 'true' }}
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
|
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
|
||||||
|
|||||||
Reference in New Issue
Block a user