gorden5566 commented on issue #3450:
URL: https://github.com/apache/rocketmq/issues/3450#issuecomment-964371793


   > Will the following command fulfill your requirement, which is not used 
option `-r` `JAVA_MAJOR_VERSION=$("$JAVA" -version 2>&1 | head -1 | cut -d'"' 
-f2 | sed 's/^1\.//' | cut -d'.' -f1)`
   
   I test the script for several java version, it works fine
   
   ```
   result -> java version
   
   8 -> java version "1.8.0_201"
   9 -> java version "9.0.4"
   10 -> java version "10" 2018-03-20
   10 -> java version "10.0.1" 2018-04-17
   17 -> openjdk version "17" 2021-09-14
   17 -> openjdk version "17.0.1" 2021-10-19
   ```


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to