build: require Go 1.27 and run CI on the go.mod version
- commit
- 93dc6b16c06ae816cef586e74ca500127cf81ab3
- author
- brice · · 2026-10-08 19:07 UTC
- parent
- 2c367cd
- signature
- GPG Verified
CD88F9E564E0102646FB6077A1A07C7C7C3E349D· arch-gpg Verified for the committer email - refs
- tag: v0.1.1
4 files · +3 -9
M .github/workflows/ci.yml +1 -6
| @@ -11,18 +11,13 @@ concurrency: | |||
| 11 | 11 | jobs: | |
| 12 | 12 | check: | |
| 13 | 13 | runs-on: ubuntu-latest | |
| 14 | - | strategy: | |
| 15 | - | matrix: | |
| 16 | - | # The oldest supported Go and the newest: allocation behaviour | |
| 17 | - | # differs between compiler versions. | |
| 18 | - | go: ['1.24', stable] | |
| 19 | 14 | steps: | |
| 20 | 15 | - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| 21 | 16 | with: | |
| 22 | 17 | persist-credentials: false | |
| 23 | 18 | - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 | |
| 24 | 19 | with: | |
| 25 | - | go-version: ${{ matrix.go }} | |
| 20 | + | go-version-file: go.mod | |
| 26 | 21 | # dbus-daemon runs the integration tests against a private bus. | |
| 27 | 22 | - run: sudo apt-get update && sudo apt-get install -y --no-install-recommends dbus | |
| 28 | 23 | - run: test -z "$(gofmt -l .)" | |
| @@ -11,18 +11,13 @@ concurrency: | |||||
| 11 | jobs: | 11 | jobs: | ||
| 12 | check: | 12 | check: | ||
| 13 | runs-on: ubuntu-latest | 13 | runs-on: ubuntu-latest | ||
| 14 | - | strategy: | |||
| 15 | - | matrix: | |||
| 16 | - | # The oldest supported Go and the newest: allocation behaviour | |||
| 17 | - | # differs between compiler versions. | |||
| 18 | - | go: ['1.24', stable] | |||
| 19 | steps: | 14 | steps: | ||
| 20 | - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | 15 | - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | ||
| 21 | with: | 16 | with: | ||
| 22 | persist-credentials: false | 17 | persist-credentials: false | ||
| 23 | - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 | 18 | - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 | ||
| 24 | with: | 19 | with: | ||
| 25 | - | go-version: ${{ matrix.go }} | 20 | + | go-version-file: go.mod |
| 26 | # dbus-daemon runs the integration tests against a private bus. | 21 | # dbus-daemon runs the integration tests against a private bus. | ||
| 27 | - run: sudo apt-get update && sudo apt-get install -y --no-install-recommends dbus | 22 | - run: sudo apt-get update && sudo apt-get install -y --no-install-recommends dbus | ||
| 28 | - run: test -z "$(gofmt -l .)" | 23 | - run: test -z "$(gofmt -l .)" | ||
M README.md +1 -1
| @@ -3,7 +3,7 @@ | |||
| 3 | 3 | A small D-Bus client for Go that does not allocate once it is running. | |
| 4 | 4 | ||
| 5 | 5 | ```sh | |
| 6 | - | go get github.com/bnema/zerobus # Go 1.24 or newer | |
| 6 | + | go get github.com/bnema/zerobus # Go 1.27 or newer | |
| 7 | 7 | ``` | |
| 8 | 8 | ||
| 9 | 9 | - **Zero allocations per message.** After the first few messages warm up its buffers, a call, a reply or a signal costs no heap allocation. | |
| @@ -3,7 +3,7 @@ | |||||
| 3 | A small D-Bus client for Go that does not allocate once it is running. | 3 | A small D-Bus client for Go that does not allocate once it is running. | ||
| 4 | 4 | ||||
| 5 | ```sh | 5 | ```sh | ||
| 6 | - | go get github.com/bnema/zerobus # Go 1.24 or newer | 6 | + | go get github.com/bnema/zerobus # Go 1.27 or newer |
| 7 | ``` | 7 | ``` | ||
| 8 | 8 | ||||
| 9 | - **Zero allocations per message.** After the first few messages warm up its buffers, a call, a reply or a signal costs no heap allocation. | 9 | - **Zero allocations per message.** After the first few messages warm up its buffers, a call, a reply or a signal costs no heap allocation. | ||
M go.mod +1 -1
| @@ -1,3 +1,3 @@ | |||
| 1 | 1 | module github.com/bnema/zerobus | |
| 2 | 2 | ||
| 3 | - | go 1.24 | |
| 3 | + | go 1.27 | |
| @@ -1,3 +1,3 @@ | |||||
| 1 | module github.com/bnema/zerobus | 1 | module github.com/bnema/zerobus | ||
| 2 | 2 | ||||
| 3 | - | go 1.24 | 3 | + | go 1.27 |
M wire.go +0 -1
| @@ -161,7 +161,6 @@ func validInterface(s string) bool { | |||
| 161 | 161 | if len(s) > 255 { | |
| 162 | 162 | return false | |
| 163 | 163 | } | |
| 164 | - | // strings.Cut, not SplitSeq: before Go 1.25 the iterator allocates. | |
| 165 | 164 | n := 0 | |
| 166 | 165 | for more := true; more; n++ { | |
| 167 | 166 | var e string | |
| @@ -161,7 +161,6 @@ func validInterface(s string) bool { | |||||
| 161 | if len(s) > 255 { | 161 | if len(s) > 255 { | ||
| 162 | return false | 162 | return false | ||
| 163 | } | 163 | } | ||
| 164 | - | // strings.Cut, not SplitSeq: before Go 1.25 the iterator allocates. | |||
| 165 | n := 0 | 164 | n := 0 | ||
| 166 | for more := true; more; n++ { | 165 | for more := true; more; n++ { | ||
| 167 | var e string | 166 | var e string | ||