diff --git a/hack/update-codegen.sh b/hack/update-codegen.sh index 30cd48b80..407fa80fc 100755 --- a/hack/update-codegen.sh +++ b/hack/update-codegen.sh @@ -45,7 +45,8 @@ declare -a GOMODS=( ) echo "Setting permissions for files of relevant go modules to 644" for MOD in "${GOMODS[@]}"; do - find "$(go list -json -m -u "${MOD}" | jq -r '.Dir')" -type f -exec chmod 644 {} + + # Use 'go list' directly to avoid an external 'jq' dependency. + find "$(go list -m -f '{{.Dir}}' "${MOD}")" -type f -exec chmod 644 {} + done echo "Generating ${blue}openapi${normal}"