Skip to content

Commit 4273dd4

Browse files
upgrade to latest dependencies (#6107)
bumping knative.dev/hack 06f7aff...fc6a845: > fc6a845 Update community files (# 398) > 9724320 Fix premature codegen cleanup exit on 1 (# 397) Signed-off-by: Knative Automation <automation@knative.team>
1 parent ffaf5bf commit 4273dd4

File tree

5 files changed

+17
-15
lines changed

5 files changed

+17
-15
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ require (
1414
google.golang.org/grpc v1.56.3
1515
gopkg.in/go-playground/webhooks.v3 v3.13.0
1616
gopkg.in/yaml.v2 v2.3.0
17-
knative.dev/hack v0.0.0-20240814130635-06f7aff93954
17+
knative.dev/hack v0.0.0-20240909014011-fc6a8452af6d
1818
)
1919

2020
require (

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -241,5 +241,5 @@ honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWh
241241
honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
242242
honnef.co/go/tools v0.0.1-2020.1.5 h1:nI5egYTGJakVyOryqLs1cQO5dO0ksin5XXs2pspk75k=
243243
honnef.co/go/tools v0.0.1-2020.1.5/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
244-
knative.dev/hack v0.0.0-20240814130635-06f7aff93954 h1:dGMK5VoL75szvrYQTL9NqhPYHu1f5dGaXx1hJI8fAFM=
245-
knative.dev/hack v0.0.0-20240814130635-06f7aff93954/go.mod h1:R0ritgYtjLDO9527h5vb5X6gfvt5LCrJ55BNbVDsWiY=
244+
knative.dev/hack v0.0.0-20240909014011-fc6a8452af6d h1:mgROhGJG3+g0SBkaG4Y2HxrIOLN3ZZcN4+IFZla+Zqs=
245+
knative.dev/hack v0.0.0-20240909014011-fc6a8452af6d/go.mod h1:R0ritgYtjLDO9527h5vb5X6gfvt5LCrJ55BNbVDsWiY=

vendor/knative.dev/hack/codegen-library.sh

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -133,16 +133,18 @@ function restore-changes-if-its-copyright-year-only() {
133133
local difflist
134134
log "Cleaning up generated code"
135135
difflist="$(mktemp)"
136-
git diff --exit-code --name-only > "$difflist"
137-
# list git changes and skip those which differ only in the boilerplate year
138-
while read -r file; do
139-
# check if the file contains just the change in the boilerplate year
140-
if [ "$(LANG=C git diff --exit-code --shortstat -- "$file")" = ' 1 file changed, 1 insertion(+), 1 deletion(-)' ] && \
141-
[[ "$(git diff --exit-code -U1 -- "$file" | grep -Ec '^[+-]\s*[*#]?\s*Copyright 2[0-9]{3}')" -eq 2 ]]; then
142-
# restore changes to that file
143-
git checkout -- "$file"
144-
fi
145-
done < "$difflist"
136+
if ! git diff --exit-code --name-only > /dev/null; then
137+
# list git changes and skip those which differ only in the boilerplate year
138+
git diff --name-only > "$difflist"
139+
while read -r file; do
140+
# check if the file contains just the change in the boilerplate year
141+
if [ "$(LANG=C git diff --exit-code --shortstat -- "$file")" = ' 1 file changed, 1 insertion(+), 1 deletion(-)' ] && \
142+
[[ "$(git diff --exit-code -U1 -- "$file" | grep -Ec '^[+-]\s*[*#]?\s*Copyright 2[0-9]{3}')" -eq 2 ]]; then
143+
# restore changes to that file
144+
git checkout -- "$file"
145+
fi
146+
done < "$difflist"
147+
fi
146148
rm -f "$difflist"
147149
}
148150

vendor/knative.dev/hack/library.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -774,7 +774,7 @@ function go_update_deps() {
774774
function __clean_goworksum_if_exists() {
775775
if [ -f "$REPO_ROOT_DIR/go.work.sum" ]; then
776776
log.step 'Cleaning the go.work.sum file'
777-
truncate --size 0 "$REPO_ROOT_DIR/go.work.sum"
777+
truncate -s 0 "$REPO_ROOT_DIR/go.work.sum"
778778
fi
779779
}
780780

vendor/modules.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ gopkg.in/go-playground/webhooks.v3/github
318318
gopkg.in/yaml.v2
319319
# honnef.co/go/tools v0.0.1-2020.1.5
320320
## explicit; go 1.11
321-
# knative.dev/hack v0.0.0-20240814130635-06f7aff93954
321+
# knative.dev/hack v0.0.0-20240909014011-fc6a8452af6d
322322
## explicit; go 1.21
323323
knative.dev/hack
324324
# go.opencensus.io => go.opencensus.io v0.20.2

0 commit comments

Comments
 (0)