zentol commented on code in PR #38:
URL: 
https://github.com/apache/flink-connector-shared-utils/pull/38#discussion_r1497786866


##########
_utils.sh:
##########
@@ -68,4 +68,15 @@ function set_pom_version {
   new_version=$1
 
   ${MVN} org.codehaus.mojo:versions-maven-plugin:2.8.1:set 
-DnewVersion=${new_version} -DgenerateBackupPoms=false --quiet
+}
+
+function is_flink_version_set_in_pom {
+  set +u
+  version=$(${MVN} help:evaluate -Dexpression="flink.version" -q -DforceStdout)
+  if [ -n "${version}" ]; then

Review Comment:
   This isn't quite reliable because it fails if the pom doesn't contain a 
reference to `flink.version` at all (e.g. the Flink repo).
   There it prints `null object or invalid expression`.
   It works for the parent pom because it does define an empty `flink.version` 
property, mostly for documentation purposes.
   Would be good to harden this so we don't fall into a trap in the future.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to