Skip to content

Commit 5660a12

Browse files
committed
ci: Migrate to paths-filter
The technote-space/get-diff-action repo is no longer maintained and archived. Last commit was 2 years ago. On the other hand dorny/paths-filter is actively maintained, last commit was 6 months ago and has far more stars 2100 vs 190 for get-diff-action. Last but not least paths-filter would better handle push force scenario.
1 parent 12a18d7 commit 5660a12

File tree

1 file changed

+19
-14
lines changed

1 file changed

+19
-14
lines changed

.github/workflows/build.yml

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ on:
77
- main
88
- release/**
99
- upgrade/**
10+
# TODO: debugging
11+
- feature/paths-filter
1012
permissions:
1113
contents: read
1214

@@ -21,21 +23,24 @@ jobs:
2123
matrix:
2224
go-arch: ["amd64"]
2325
steps:
24-
- uses: actions/checkout@v3
25-
- uses: actions/setup-go@v3
26+
- uses: actions/checkout@v4
27+
- uses: actions/setup-go@v5
2628
with:
2729
go-version: "^1.21"
28-
- uses: technote-space/get-diff-action@v6.1.2
29-
id: git_diff
30+
- uses: dorny/paths-filter@v3
31+
id: filter
3032
with:
31-
PATTERNS: |
32-
**/*.go
33-
go.mod
34-
go.sum
35-
**/go.mod
36-
**/go.sum
37-
**/Makefile
38-
Makefile
33+
filters: |
34+
go:
35+
- '**/*.go'
36+
- 'go.mod'
37+
- 'go.sum'
38+
- '**/go.mod'
39+
- '**/go.sum'
40+
- '**/Makefile'
41+
- 'Makefile'
42+
- '.github/workflows/build.yml'
43+
3944
- name: Build
40-
if: env.GIT_DIFF
41-
run: GOARCH=${{ matrix.go-arch }} LEDGER_ENABLED=false make build
45+
if: steps.filter.outputs.go == 'true'
46+
run: echo TODO debugging GOARCH=${{ matrix.go-arch }} LEDGER_ENABLED=false make build

0 commit comments

Comments
 (0)