From 7048c24f0be4eaead8380d776afb1009f68047c1 Mon Sep 17 00:00:00 2001 From: Andrey Smirnov Date: Tue, 27 Aug 2024 20:17:35 +0400 Subject: [PATCH] feat: bump dependencies Go modules, buildkit, various deps. Signed-off-by: Andrey Smirnov --- Dockerfile | 4 +- Makefile | 8 ++-- go.mod | 2 +- go.sum | 4 +- hack/release.sh | 61 ++++++++++++++------------- internal/config/constants.go | 10 ++--- internal/output/github/github.go | 2 +- internal/project/common/repository.go | 2 +- 8 files changed, 48 insertions(+), 45 deletions(-) diff --git a/Dockerfile b/Dockerfile index 749544e..4a67969 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ # THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT. # -# Generated on 2024-08-12T07:50:42Z by kres 362381e. +# Generated on 2024-08-27T16:16:08Z by kres 8e4bbb4-dirty. ARG TOOLCHAIN @@ -11,7 +11,7 @@ FROM ghcr.io/siderolabs/ca-certificates:v1.7.0 AS image-ca-certificates FROM ghcr.io/siderolabs/fhs:v1.7.0 AS image-fhs # runs markdownlint -FROM docker.io/oven/bun:1.1.22-alpine AS lint-markdown +FROM docker.io/oven/bun:1.1.26-alpine AS lint-markdown WORKDIR /src RUN bun i markdownlint-cli@0.41.0 sentences-per-line@0.2.1 COPY .markdownlint.json . diff --git a/Makefile b/Makefile index b89e634..9a6cac0 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ # THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT. # -# Generated on 2024-08-14T03:23:02Z by kres ac31db2. +# Generated on 2024-08-27T16:16:08Z by kres 8e4bbb4-dirty. # common variables @@ -19,12 +19,12 @@ USERNAME ?= siderolabs REGISTRY_AND_USERNAME ?= $(REGISTRY)/$(USERNAME) PROTOBUF_GO_VERSION ?= 1.34.2 GRPC_GO_VERSION ?= 1.5.1 -GRPC_GATEWAY_VERSION ?= 2.21.0 +GRPC_GATEWAY_VERSION ?= 2.22.0 VTPROTOBUF_VERSION ?= 0.6.0 GOIMPORTS_VERSION ?= 0.24.0 DEEPCOPY_VERSION ?= v0.5.6 -GOLANGCILINT_VERSION ?= v1.60.1 -GOFUMPT_VERSION ?= v0.6.0 +GOLANGCILINT_VERSION ?= v1.60.3 +GOFUMPT_VERSION ?= v0.7.0 GO_VERSION ?= 1.23.0 GO_BUILDFLAGS ?= GO_LDFLAGS ?= diff --git a/go.mod b/go.mod index b7c803c..4a51497 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.23.0 require ( github.com/drone/drone-yaml v1.2.3 github.com/go-git/go-git/v5 v5.12.0 - github.com/google/go-github/v63 v63.0.0 + github.com/google/go-github/v64 v64.0.0 github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 github.com/siderolabs/gen v0.5.0 github.com/spf13/cobra v1.8.1 diff --git a/go.sum b/go.sum index d0cad4b..544b897 100644 --- a/go.sum +++ b/go.sum @@ -64,8 +64,8 @@ github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5a github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-github/v63 v63.0.0 h1:13xwK/wk9alSokujB9lJkuzdmQuVn2QCPeck76wR3nE= -github.com/google/go-github/v63 v63.0.0/go.mod h1:IqbcrgUmIcEaioWrGYei/09o+ge5vhffGOcxrO0AfmA= +github.com/google/go-github/v64 v64.0.0 h1:4G61sozmY3eiPAjjoOHponXDBONm+utovTKbyUb2Qdg= +github.com/google/go-github/v64 v64.0.0/go.mod h1:xB3vqMQNdHzilXBiO2I+M7iEFtHf+DP/omBOv6tQzVo= github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= diff --git a/hack/release.sh b/hack/release.sh index 54d9cf3..856c255 100755 --- a/hack/release.sh +++ b/hack/release.sh @@ -2,7 +2,7 @@ # THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT. # -# Generated on 2024-08-21T15:32:28Z by kres 2c0b663. +# Generated on 2024-08-27T16:16:08Z by kres 8e4bbb4-dirty. set -e @@ -97,34 +97,37 @@ function is_on_main_branch { } function update_license_files { - script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" - parent_dir="$(dirname "$script_dir")" - current_year=$(date +"%Y") - change_date=$(date -v+4y +"%Y-%m-%d" 2>/dev/null || date -d "+4 years" +"%Y-%m-%d" 2>/dev/null || date --date="+4 years" +"%Y-%m-%d") - - # Find LICENSE files recursively in the parent directory - find "$parent_dir" -type f -name "LICENSE" | while read -r file; do - # Check if file starts with "Business Source License" - if grep -q "^Business Source License" "$file"; then - # Create a temporary file - temp_file="${file}.tmp" - - # Update the year and the change date - sed -e "s/The Licensed Work is (c) [0-9]\{4\}/The Licensed Work is (c) $current_year/" \ - -e "s/Change Date: [0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\}/Change Date: $change_date/" \ - "$file" > "$temp_file" - - # Check if the file has changed - if ! cmp -s "$file" "$temp_file"; then - mv "$temp_file" "$file" - echo "Updated: $file" - git add "$file" - else - echo "No changes: $file" - rm "$temp_file" - fi - fi - done + script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" + parent_dir="$(dirname "$script_dir")" + current_year=$(date +"%Y") + change_date=$(date -v+4y +"%Y-%m-%d" 2>/dev/null || date -d "+4 years" +"%Y-%m-%d" 2>/dev/null || date --date="+4 years" +"%Y-%m-%d") + + # Find LICENSE and .kres.yaml files recursively in the parent directory (project root) + find "$parent_dir" \( -name "LICENSE" -o -name ".kres.yaml" \) -type f | while read -r file; do + temp_file="${file}.tmp" + + if [[ $file == *"LICENSE" ]]; then + if grep -q "^Business Source License" "$file"; then + sed -e "s/The Licensed Work is (c) [0-9]\{4\}/The Licensed Work is (c) $current_year/" \ + -e "s/Change Date: [0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\}/Change Date: $change_date/" \ + "$file" >"$temp_file" + else + continue # Not a Business Source License file + fi + elif [[ $file == *".kres.yaml" ]]; then + sed -E 's/^([[:space:]]*)ChangeDate:.*$/\1ChangeDate: "'"$change_date"'"/' "$file" >"$temp_file" + fi + + # Check if the file has changed + if ! cmp -s "$file" "$temp_file"; then + mv "$temp_file" "$file" + echo "Updated: $file" + git add "$file" + else + echo "No changes: $file" + rm "$temp_file" + fi + done } if declare -f "$1" > /dev/null diff --git a/internal/config/constants.go b/internal/config/constants.go index 95ecd81..13e233d 100644 --- a/internal/config/constants.go +++ b/internal/config/constants.go @@ -21,7 +21,7 @@ const ( // BuildKitContainerVersion is the version of buildkit container image. // renovate: datasource=docker versioning=docker depName=moby/buildkit - BuildKitContainerVersion = "v0.15.1" + BuildKitContainerVersion = "v0.15.2" // CheckOutActionVersion is the version of checkout github action. // renovate: datasource=github-releases extractVersion=^(?v\d+)\.\d+\.\d+$ depName=actions/checkout CheckOutActionVersion = "v4" @@ -45,13 +45,13 @@ const ( GitHubScriptActionVersion = "v7" // GoFmtVersion is the version of gofmt. // renovate: datasource=go depName=github.com/mvdan/gofumpt - GoFmtVersion = "v0.6.0" + GoFmtVersion = "v0.7.0" // GoImportsVersion is the version of goimports. // renovate: datasource=go depName=golang.org/x/tools GoImportsVersion = "v0.24.0" // GolangCIlintVersion is the version of golangci-lint. // renovate: datasource=go depName=github.com/golangci/golangci-lint - GolangCIlintVersion = "v1.60.1" + GolangCIlintVersion = "v1.60.3" // GolangContainerImageVersion is the default golang container image. // renovate: datasource=docker versioning=docker depName=golang GolangContainerImageVersion = "1.23-alpine" @@ -60,7 +60,7 @@ const ( GoVersion = "1.23.0" // GrpcGatewayVersion is the version of grpc-gateway. // renovate: datasource=go depName=github.com/grpc-ecosystem/grpc-gateway - GrpcGatewayVersion = "v2.21.0" + GrpcGatewayVersion = "v2.22.0" // GrpcGoVersion is the version of grpc. // renovate: datasource=go depName=google.golang.org/grpc/cmd/protoc-gen-go-grpc GrpcGoVersion = "v1.5.1" @@ -72,7 +72,7 @@ const ( MardownLintCLIVersion = "0.41.0" // BunContainerImageVersion is the default bun container image. // renovate: datasource=docker versioning=docker depName=oven/bun - BunContainerImageVersion = "1.1.22-alpine" + BunContainerImageVersion = "1.1.26-alpine" // PkgsVersion is the version of pkgs. // renovate: datasource=github-tags depName=siderolabs/pkgs PkgsVersion = "v1.7.0" diff --git a/internal/output/github/github.go b/internal/output/github/github.go index d34ac49..905e2b8 100644 --- a/internal/output/github/github.go +++ b/internal/output/github/github.go @@ -10,7 +10,7 @@ import ( "fmt" "os" - "github.com/google/go-github/v63/github" + "github.com/google/go-github/v64/github" "golang.org/x/oauth2" ) diff --git a/internal/project/common/repository.go b/internal/project/common/repository.go index 1caea08..ab0e048 100644 --- a/internal/project/common/repository.go +++ b/internal/project/common/repository.go @@ -10,7 +10,7 @@ import ( "net/http" "slices" - "github.com/google/go-github/v63/github" + "github.com/google/go-github/v64/github" "github.com/siderolabs/gen/xslices" "github.com/siderolabs/kres/internal/config"