halcyon / asdf-java

A Java plugin for asdf-vm.
MIT License
455 stars 86 forks source link

Error: Permission denied after using the asdf list-all java command #232

Open zwh8800 opened 3 weeks ago

zwh8800 commented 3 weeks ago

Hello,

I just used the command asdf plugin-add java https://github.com/halcyon/asdf-java.git to install this plugin. However, when I used the command asdf list-all java to list the candidate JDKs, I encountered the following error:

Plugin java's list-all callback script failed with output:
/Users/wastecat/.asdf/lib/functions/versions.bash: line 98: /Users/wastecat/.asdf/plugins/java/bin/list-all: Permission denied

My system is macOS 14.4.1, Apple M3 Pro.

obscurelyme commented 2 weeks ago

I had experienced this same issue. Running chmod on the functions file wasn't working or anything else for that matter, but I was able to leverage a hacky workaround by deleting the symlinks inside ~/.asdf/installs/java/bin and then recreating them. Happy to know of a better solution if one exists.