mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-08 20:50:24 +00:00
propagate pinned versions to staging repos, output cleanup commands
This commit is contained in:
@@ -91,5 +91,15 @@ echo "Resolved to ${dep}@${rev}"
|
||||
echo "Running: go mod edit -replace ${dep}=${dep}@${rev}"
|
||||
go mod edit -replace "${dep}=${dep}@${rev}"
|
||||
|
||||
# Propagate pinned version to staging repos that also have that dependency
|
||||
for repo in $(ls staging/src/k8s.io | sort); do
|
||||
pushd "staging/src/k8s.io/${repo}" >/dev/null 2>&1
|
||||
if go mod edit -json | jq -e -r ".Require[] | select(.Path == \"${dep}\")" > /dev/null; then
|
||||
go mod edit -require "${dep}@${rev}"
|
||||
go mod edit -replace "${dep}=${dep}@${rev}"
|
||||
fi
|
||||
popd >/dev/null 2>&1
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo "Run hack/update-vendor.sh to rebuild the vendor directory"
|
||||
|
Reference in New Issue
Block a user