Skip to content

Commit

Permalink
Require manual Go version updates for patch versions (jaegertracing#5848
Browse files Browse the repository at this point in the history
)
  • Loading branch information
wasup-yash committed Aug 15, 2024
1 parent 4595cfe commit 57479c1
Showing 1 changed file with 5 additions and 1 deletion.
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

0 comments on commit 57479c1

Please sign in to comment.