From 8852798aa0c0fedb0aa3629c13f00c990e2e0488 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:13:11 +0200 Subject: [PATCH 1/9] chore: fix lint Signed-off-by: Manfred Touron <94029+moul@users.noreply.github.com> --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index 555dc03..26149fa 100644 --- a/main.go +++ b/main.go @@ -78,7 +78,7 @@ func run(args []string) error { return nil } -func doRoot(ctx context.Context, args []string) error { +func doRoot(_ context.Context, args []string) error { if len(args) > 0 { return flag.ErrHelp } From 12433ba4e550df3854ca576b3a80543249d4f12e Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:14:54 +0200 Subject: [PATCH 2/9] chore: bump deps Signed-off-by: Manfred Touron <94029+moul@users.noreply.github.com> --- depaware.txt | 20 +++++++++++++------- go.mod | 8 ++++---- go.sum | 14 ++++++++------ 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/depaware.txt b/depaware.txt index 8e4595f..1827432 100644 --- a/depaware.txt +++ b/depaware.txt @@ -1,14 +1,18 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/depaware) - go.uber.org/atomic from go.uber.org/multierr+ + github.com/peterbourgon/ff/v3 from moul.io/climan+ + github.com/peterbourgon/ff/v3/internal from github.com/peterbourgon/ff/v3 + 💣 go.uber.org/atomic from go.uber.org/zap+ go.uber.org/multierr from go.uber.org/zap+ - go.uber.org/zap from moul.io/zapconfig + go.uber.org/zap from moul.io/zapconfig+ go.uber.org/zap/buffer from go.uber.org/zap/internal/bufferpool+ + go.uber.org/zap/internal from go.uber.org/zap go.uber.org/zap/internal/bufferpool from go.uber.org/zap+ go.uber.org/zap/internal/color from go.uber.org/zap/zapcore go.uber.org/zap/internal/exit from go.uber.org/zap/zapcore go.uber.org/zap/zapcore from go.uber.org/zap+ moul.io/banner from moul.io/motd + moul.io/climan from moul.io/golang-repo-template moul.io/motd from moul.io/golang-repo-template moul.io/srand from moul.io/golang-repo-template moul.io/u from moul.io/golang-repo-template @@ -17,9 +21,7 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de golang.org/x/crypto/chacha20poly1305 from crypto/tls golang.org/x/crypto/cryptobyte from crypto/ecdsa+ golang.org/x/crypto/cryptobyte/asn1 from crypto/ecdsa+ - golang.org/x/crypto/curve25519 from crypto/tls golang.org/x/crypto/hkdf from crypto/tls - golang.org/x/crypto/poly1305 from golang.org/x/crypto/chacha20poly1305 golang.org/x/net/dns/dnsmessage from net golang.org/x/net/http/httpguts from net/http golang.org/x/net/http/httpproxy from net/http @@ -43,6 +45,7 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de crypto/cipher from crypto/aes+ crypto/des from crypto/tls+ crypto/dsa from crypto/x509 + crypto/ecdh from crypto/ecdsa+ crypto/ecdsa from crypto/tls+ crypto/ed25519 from crypto/tls+ crypto/elliptic from crypto/ecdsa+ @@ -58,7 +61,8 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de crypto/tls from net/http+ crypto/x509 from crypto/tls crypto/x509/pkix from crypto/x509 - encoding from encoding/json + embed from crypto/internal/nistec+ + encoding from encoding/json+ encoding/asn1 from crypto/x509+ encoding/base64 from encoding/json+ encoding/binary from archive/zip+ @@ -66,13 +70,13 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de encoding/json from go.uber.org/atomic+ encoding/pem from crypto/tls+ errors from archive/zip+ - flag from go.uber.org/zap + flag from go.uber.org/zap+ fmt from compress/flate+ hash from archive/zip+ hash/crc32 from archive/zip+ io from archive/zip+ io/fs from archive/zip+ - io/ioutil from crypto/x509+ + io/ioutil from golang.org/x/sys/cpu+ log from go.uber.org/zap+ math from compress/flate+ math/big from crypto/dsa+ @@ -85,6 +89,7 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de net/http from go.uber.org/zap net/http/httptrace from net/http net/http/internal from net/http + net/netip from net net/textproto from golang.org/x/net/http/httpguts+ net/url from crypto/x509+ os from archive/zip+ @@ -100,6 +105,7 @@ moul.io/golang-repo-template dependencies: (generated by github.com/tailscale/de sync from archive/zip+ sync/atomic from context+ syscall from crypto/rand+ + text/tabwriter from moul.io/climan time from archive/zip+ unicode from bytes+ unicode/utf16 from encoding/asn1+ diff --git a/go.mod b/go.mod index 7a196db..18ff5f6 100644 --- a/go.mod +++ b/go.mod @@ -3,10 +3,10 @@ module moul.io/golang-repo-template go 1.19 require ( - github.com/peterbourgon/ff/v3 v3.3.1 + github.com/peterbourgon/ff/v3 v3.4.0 github.com/tailscale/depaware v0.0.0-20210622194025-720c4b409502 go.uber.org/goleak v1.2.1 - go.uber.org/zap v1.23.0 + go.uber.org/zap v1.24.0 moul.io/climan v1.0.0 moul.io/motd v1.0.0 moul.io/srand v1.6.1 @@ -16,8 +16,8 @@ require ( require ( github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e // indirect - go.uber.org/atomic v1.7.0 // indirect - go.uber.org/multierr v1.7.0 // indirect + go.uber.org/atomic v1.11.0 // indirect + go.uber.org/multierr v1.11.0 // indirect golang.org/x/mod v0.4.2 // indirect golang.org/x/sys v0.1.0 // indirect golang.org/x/tools v0.1.5 // indirect diff --git a/go.sum b/go.sum index 9c9f208..b7424ee 100644 --- a/go.sum +++ b/go.sum @@ -13,8 +13,8 @@ github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/pelletier/go-toml v1.6.0/go.mod h1:5N711Q9dKgbdkxHL+MEfF31hpT7l0S0s/t2kKREewys= github.com/peterbourgon/ff/v3 v3.0.0/go.mod h1:UILIFjRH5a/ar8TjXYLTkIvSvekZqPm5Eb/qbGk6CT0= -github.com/peterbourgon/ff/v3 v3.3.1 h1:XSWvXxeNdgeppLNGGJEAOiXRdX2YMF/LuZfdnqQ1SNc= -github.com/peterbourgon/ff/v3 v3.3.1/go.mod h1:zjJVUhx+twciwfDl0zBcFzl4dW8axCRyXE/eKY9RztQ= +github.com/peterbourgon/ff/v3 v3.4.0 h1:QBvM/rizZM1cB0p0lGMdmR7HxZeI/ZrBWB4DqLkMUBc= +github.com/peterbourgon/ff/v3 v3.4.0/go.mod h1:zjJVUhx+twciwfDl0zBcFzl4dW8axCRyXE/eKY9RztQ= github.com/pkg/diff v0.0.0-20200914180035-5b29258ca4f7/go.mod h1:zO8QMzTeZd5cpnIkz/Gn6iK0jDfGicM1nynOkkPIl28= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e h1:aoZm08cpOy4WuID//EZDgcC4zIxODThtZNPirFr42+A= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= @@ -34,17 +34,19 @@ github.com/tailscale/depaware v0.0.0-20210622194025-720c4b409502 h1:34icjjmqJ2HP github.com/tailscale/depaware v0.0.0-20210622194025-720c4b409502/go.mod h1:p9lPsd+cx33L3H9nNoecRRxPssFKUwwI50I3pZ0yT+8= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/atomic v1.7.0 h1:ADUqmZGgLDDfbSL9ZmPxKTybcoEYHgpYfELNoN+7hsw= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= +go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE= +go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4= go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= -go.uber.org/multierr v1.7.0 h1:zaiO/rmgFjbmCXdSYJWQcdvOCsthmdaHfr3Gm2Kx4Ec= go.uber.org/multierr v1.7.0/go.mod h1:7EAYxJLBy9rStEaz58O2t4Uvip6FSURkq8/ppBp95ak= +go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= +go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ= -go.uber.org/zap v1.23.0 h1:OjGQ5KQDEUawVHxNwQgPpiypGHOxo2mNZsOqTak4fFY= -go.uber.org/zap v1.23.0/go.mod h1:D+nX8jyLsMHMYrln8A0rJjFt/T/9/bGgIhAqxv5URuY= +go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= +go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= From 4c6573b9a26ed9f48a8757bf668d0815d167b777 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:15:59 +0200 Subject: [PATCH 3/9] chore: regenerate Signed-off-by: Manfred Touron <94029+moul@users.noreply.github.com> --- .gitignore | 1 + AUTHORS | 3 +++ 2 files changed, 4 insertions(+) diff --git a/.gitignore b/.gitignore index b8f3991..7169b56 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ go-test.json *# .#* coverage.txt +/.tmp/ go-build.log go-install.log diff --git a/AUTHORS b/AUTHORS index 35060c1..401717f 100644 --- a/AUTHORS +++ b/AUTHORS @@ -6,9 +6,12 @@ Darko Djalevski Darko Djalevski dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> +Isma <71719097+Doozers@users.noreply.github.com> Manfred Touron <94029+moul@users.noreply.github.com> Manfred Touron +moul <94029+moul@users.noreply.github.com> moul-bot Renovate Bot renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> +semgrep.dev on behalf of @moul Stavros Panakakis <53979866+Stavrospanakakis@users.noreply.github.com> From 1f9324916dbd646f5688e4d8780d86fa341037f5 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:17:26 +0200 Subject: [PATCH 4/9] chore: fixup --- .golangci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.golangci.yml b/.golangci.yml index 347f732..1bc88d5 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -20,7 +20,6 @@ linters: enable: - asciicheck - bodyclose - - deadcode - depguard - dogsled - dupl From 88e27108edc94520fb7811b4c4c6444097917bec Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:18:11 +0200 Subject: [PATCH 5/9] chore: fixup --- .goreleaser.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index dd3c164..31df193 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -39,12 +39,12 @@ changelog: archives: - name_template: '{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}' - replacements: - darwin: Darwin - linux: Linux - windows: Windows - 386: i386 - amd64: x86_64 + #replacements: + # darwin: Darwin + # linux: Linux + # windows: Windows + # 386: i386 + # amd64: x86_64 format_overrides: - goos: windows From 04269d81d91bda827a2260366ab3a35987df8501 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:19:16 +0200 Subject: [PATCH 6/9] chore: fix import paths --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index 26149fa..5fd0362 100644 --- a/main.go +++ b/main.go @@ -8,7 +8,7 @@ import ( "math/rand" "os" - "github.com/peterbourgon/ff/v3" + ff "github.com/peterbourgon/ff/v3" "go.uber.org/zap" "go.uber.org/zap/zapcore" "moul.io/climan" From e598c7435e2b5b9ea3e2fd9f473d3f0426d00de4 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:21:26 +0200 Subject: [PATCH 7/9] chore: fix release-note --- .github/workflows/pr.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 46e90e1..5b2fae5 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -17,7 +17,7 @@ jobs: git fetch --prune --unshallow --tags - uses: snyk/release-notes-preview@v1.6.2 with: - releaseBranch: master + releaseBranch: ${{ github.event.repository.default_branch }} env: GITHUB_PR_USERNAME: ${{ github.actor }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 4ad80c1704f7f5d62dec1796b7485d019e3b699a Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:22:20 +0200 Subject: [PATCH 8/9] chore: fix golangci-lint --- .github/workflows/go.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index fd77876..2754b9a 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -73,7 +73,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - golangci_lint: [v1.50.1] + golangci_lint: [v1.53.3] golang: [1.20.x] steps: - uses: actions/checkout@v3 From d4f23b8bd7fef6da02ad9b7910aded95dd13bc74 Mon Sep 17 00:00:00 2001 From: Manfred Touron <94029+moul@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:44:03 +0200 Subject: [PATCH 9/9] chore: disable depguard --- .golangci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.golangci.yml b/.golangci.yml index 1bc88d5..5d8025e 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -20,7 +20,7 @@ linters: enable: - asciicheck - bodyclose - - depguard + #- depguard - dogsled - dupl - errcheck