Skip to content

Commit

Permalink
Added comment for future people who wish to make the regex and if nicer
Browse files Browse the repository at this point in the history
  • Loading branch information
judovana committed May 3, 2024
1 parent 534bddc commit df07f73
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions sbin/common/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ function setOpenJdkVersion() {
# If your repository has a different name, you can use --version or build from dir/snapshot
local forest_name_check1=0
local forest_name_check2=0
# this unhappy two returns condition is there to make grep on solaris happy. -e, -q and \( and \| seems to not be working
echo "$forest_name" | grep "^jdk[0-9]\\{1,3\\}[u]\\{0,1\\}$" >/dev/null || forest_name_check1=$?
echo "$forest_name" | grep "^jdk$" >/dev/null || forest_name_check2=$?
if [ ${forest_name_check1} -ne 0 ] && [ ${forest_name_check2} -ne 0 ]; then
Expand Down

0 comments on commit df07f73

Please sign in to comment.