Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion scripts/check-go-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,11 @@ function check() {
fi

if [[ $update = true && "$mismatch" != "" ]]; then
# Detect if the line includes a patch version
if [[ "$go_version" =~ $version_regex\.[0-9]+ ]]; then
echo "Patch version detected in $file. Manual update required."
exit 1
fi
update "$file" "$pattern" "$go_version" "$target"
mismatch="*** => $target ***"
fi
Expand All @@ -78,7 +83,6 @@ function check() {

check go.mod "^go\s\+$version_regex" "$go_previous_version"
check internal/tools/go.mod "^go\s\+$version_regex" "$go_latest_version"

check docker/debug/Dockerfile "^.*golang:$version_regex" "$go_latest_version"

IFS='|' read -r -a gha_workflows <<< "$(grep -rl go-version .github | tr '\n' '|')"
Expand Down