diff options
author | Max Harmathy | 2024-03-28 09:55:29 +0100 |
---|---|---|
committer | Max Harmathy | 2024-03-28 10:20:36 +0100 |
commit | 775541fa89c2112297231287467a63b4e58c7456 (patch) | |
tree | 7526e7a4b7e38eecf90a32857a76b62fa4406682 /PKGBUILD | |
parent | cd646886fdcb03d8691fefed3cf9cbccb1b66480 (diff) | |
download | aur-775541fa89c2112297231287467a63b4e58c7456.tar.gz |
Make Java check more robust
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -34,8 +34,9 @@ b2sums=('a24308a98714b05d8df34bf06d64e3854ed9b826276b0ea576c23cebdf2ffd47139c003 build() { # check for correct java version - read -a javac_version < <(javac --version) - if [ ! "${javac_version[1]}" = "21" ]; then + local status='' + read -a javac_version < <(javac --version) || status='failed' + if [ -n "$status" ] || [ ! "${javac_version[1]%%.*}" = "21" ]; then echo "Please set your java version to openjdk 21 unsing \"archlinux-java\"" >&2 return 1 fi |