Skip to content

Commit 2cc2884

Browse files
authored
chore: bump version of go tools, go compiler, and goquery (fixes CVE) (#1031)
1 parent a66a237 commit 2cc2884

File tree

46 files changed

+268
-291
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+268
-291
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ jobs:
1212
steps:
1313
- uses: actions/checkout@v4
1414

15-
- uses: cachix/install-nix-action@v25
15+
- uses: DeterminateSystems/nix-installer-action@v16
1616
with:
1717
github_access_token: ${{ secrets.GITHUB_TOKEN }}
1818

19-
- uses: DeterminateSystems/magic-nix-cache-action@v3
19+
- uses: DeterminateSystems/magic-nix-cache-action@v8
2020

2121
- name: Test
2222
run: nix develop --command xc test-cover
@@ -42,11 +42,11 @@ jobs:
4242
steps:
4343
- uses: actions/checkout@v4
4444

45-
- uses: cachix/install-nix-action@v25
45+
- uses: DeterminateSystems/nix-installer-action@v16
4646
with:
4747
github_access_token: ${{ secrets.GITHUB_TOKEN }}
4848

49-
- uses: DeterminateSystems/magic-nix-cache-action@v3
49+
- uses: DeterminateSystems/magic-nix-cache-action@v8
5050

5151
- name: Lint
5252
run: nix develop --command xc lint
@@ -56,11 +56,11 @@ jobs:
5656
steps:
5757
- uses: actions/checkout@v4
5858

59-
- uses: cachix/install-nix-action@v25
59+
- uses: DeterminateSystems/nix-installer-action@v16
6060
with:
6161
github_access_token: ${{ secrets.GITHUB_TOKEN }}
6262

63-
- uses: DeterminateSystems/magic-nix-cache-action@v3
63+
- uses: DeterminateSystems/magic-nix-cache-action@v8
6464

6565
- name: Generate
6666
run: nix develop --command xc ensure-generated
@@ -70,11 +70,11 @@ jobs:
7070
steps:
7171
- uses: actions/checkout@v4
7272

73-
- uses: cachix/install-nix-action@v25
73+
- uses: DeterminateSystems/nix-installer-action@v16
7474
with:
7575
github_access_token: ${{ secrets.GITHUB_TOKEN }}
7676

77-
- uses: DeterminateSystems/magic-nix-cache-action@v3
77+
- uses: DeterminateSystems/magic-nix-cache-action@v8
7878

7979
- name: Fmt
8080
run: nix develop --command xc fmt

.github/workflows/docs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
fetch-depth: 0
3030
- name: Setup Pages
3131
id: pages
32-
uses: actions/configure-pages@v4
32+
uses: actions/configure-pages@v5
3333
- uses: actions/setup-node@v4
3434
with:
3535
node-version: '20'

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ jobs:
2121
with:
2222
go-version: 1.22
2323
cache: true
24-
- uses: ko-build/setup-ko@v0.6
25-
- uses: sigstore/cosign-installer@v3.3.0
24+
- uses: ko-build/setup-ko@v0.7
25+
- uses: sigstore/cosign-installer@v3.7.0
2626
with:
2727
cosign-release: v2.2.3
2828
- uses: goreleaser/goreleaser-action@v5

.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.2.810
1+
0.3.812

README.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,6 @@ cd cmd/templ
2828
go build
2929
```
3030

31-
### nix-update-gomod2nix
32-
33-
```sh
34-
gomod2nix
35-
```
36-
3731
### install-snapshot
3832

3933
Build and install current version.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module testprogram
22

3-
go 1.22.6
3+
go 1.23

cmd/templ/generatecmd/testwatch/testdata/go.mod.embed

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module templ/testproject
22

3-
go 1.21
3+
go 1.23
44

55
require github.com/a-h/templ v0.2.513 // indirect
66

cmd/templ/lspcmd/lsp_test.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ func TestHover(t *testing.T) {
216216
expectedHover := protocol.Hover{
217217
Contents: protocol.MarkupContent{
218218
Kind: "markdown",
219-
Value: "```go\npackage fmt\n```\n\n[`fmt` on pkg.go.dev](https://pkg.go.dev/fmt)",
219+
Value: "```go\npackage fmt\n```\n\n---\n\n[`fmt` on pkg.go.dev](https://pkg.go.dev/fmt)",
220220
},
221221
}
222222
if diff := lspdiff.Hover(expectedHover, *actual); diff != "" {
@@ -233,9 +233,12 @@ func TestHover(t *testing.T) {
233233
expectedHover := protocol.Hover{
234234
Contents: protocol.MarkupContent{
235235
Kind: "markdown",
236-
Value: "```go\nfunc fmt.Sprintf(format string, a ...any) string\n```\n\nSprintf formats according to a format specifier and returns the resulting string.\n\n\n[`fmt.Sprintf` on pkg.go.dev](https://pkg.go.dev/fmt#Sprintf)",
236+
Value: "```go\nfunc fmt.Sprintf(format string, a ...any) string\n```\n\n---\n\nSprintf formats according to a format specifier and returns the resulting string.\n\n\n---\n\n[`fmt.Sprintf` on pkg.go.dev](https://pkg.go.dev/fmt#Sprintf)",
237237
},
238238
}
239+
if actual == nil {
240+
return "expected hover to be non-nil", false
241+
}
239242
if diff := lspdiff.Hover(expectedHover, *actual); diff != "" {
240243
return fmt.Sprintf("unexpected hover: %v", diff), false
241244
}

cmd/templ/lspcmd/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ func run(ctx context.Context, log *zap.Logger, templStream jsonrpc2.Stream, args
9595

9696
log.Info("creating gopls client")
9797
clientProxy, clientInit := proxy.NewClient(log, cache, diagnosticCache)
98-
_, goplsConn, goplsServer := protocol.NewClient(context.Background(), clientProxy, jsonrpc2.NewStream(rwc), log)
98+
_, goplsConn, goplsServer := protocol.NewClient(ctx, clientProxy, jsonrpc2.NewStream(rwc), log)
9999
defer goplsConn.Close()
100100

101101
log.Info("creating proxy")

cmd/templ/lspcmd/proxy/server.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,6 @@ func (p *Server) Initialize(ctx context.Context, params *lsp.InitializeParams) (
249249
isTemplFile, goURI := convertTemplToGoURI(uri)
250250

251251
if !isTemplFile {
252-
p.Log.Info("not a templ file", zap.String("uri", string(uri)))
253252
return nil
254253
}
255254

0 commit comments

Comments
 (0)