Skip to content

Commit 747f92d

Browse files
authored
Merge pull request #1669 from rsteube/winget-job-condition
github: move winget condition to job level
2 parents b14c52b + b38ccd5 commit 747f92d

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

.github/workflows/go.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@ jobs:
1111
container: ghcr.io/rsteube/carapace
1212
steps:
1313
- name: shallow clone
14-
uses: actions/checkout@v2
14+
uses: actions/checkout@v3
1515
if: "!startsWith(github.ref, 'refs/tags/')"
1616

1717
- name: deep clone
18-
uses: actions/checkout@v2
18+
uses: actions/checkout@v3
1919
if: startsWith(github.ref, 'refs/tags/')
2020
with:
2121
fetch-depth: 0
2222

2323
- name: Set up Go
24-
uses: actions/setup-go@v2
24+
uses: actions/setup-go@v4
2525
with:
2626
go-version: '1.20'
2727

@@ -31,7 +31,7 @@ jobs:
3131
- name: Build
3232
run: ls cmd/ | xargs -I'{}' sh -c "cd ./cmd/{} && go build -v ."
3333

34-
- uses: actions/upload-artifact@v2
34+
- uses: actions/upload-artifact@v3
3535
with:
3636
name: carapace
3737
path: ./cmd/carapace/carapace
@@ -50,7 +50,7 @@ jobs:
5050
run: go run ./cmd/caralint completers/*/cmd/*.go
5151

5252
- name: Run GoReleaser
53-
uses: goreleaser/goreleaser-action@v2
53+
uses: goreleaser/goreleaser-action@v4
5454
if: startsWith(github.ref, 'refs/tags/')
5555
with:
5656
version: latest
@@ -66,9 +66,9 @@ jobs:
6666
container: ghcr.io/rsteube/carapace
6767
needs: build
6868
steps:
69-
- uses: actions/checkout@v2
69+
- uses: actions/checkout@v3
7070

71-
- uses: actions/download-artifact@v2
71+
- uses: actions/download-artifact@v3
7272
with:
7373
name: carapace
7474
path: ./cmd/carapace
@@ -98,11 +98,11 @@ jobs:
9898

9999

100100
winget:
101+
if: startsWith(github.ref, 'refs/tags/')
101102
runs-on: windows-latest
102103
needs: build
103104
steps:
104105
- uses: vedantmgoyal2009/winget-releaser@v2
105-
if: startsWith(github.ref, 'refs/tags/')
106106
with:
107107
identifier: rsteube.Carapace
108108
max-versions-to-keep: 5

0 commit comments

Comments
 (0)