summaryrefslogtreecommitdiff
path: root/plugins/asdf
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/asdf')
-rw-r--r--plugins/asdf/asdf.plugin.zsh6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/asdf/asdf.plugin.zsh b/plugins/asdf/asdf.plugin.zsh
index da53eef8e..3016282c6 100644
--- a/plugins/asdf/asdf.plugin.zsh
+++ b/plugins/asdf/asdf.plugin.zsh
@@ -2,6 +2,12 @@
ASDF_DIR="${ASDF_DIR:-$HOME/.asdf}"
ASDF_COMPLETIONS="$ASDF_DIR/completions"
+# If not found, check for archlinux/AUR package (/opt/asdf-vm/)
+if [[ ! -f "$ASDF_DIR/asdf.sh" || ! -f "$ASDF_COMPLETIONS/asdf.bash" ]] && [[ -f "/opt/asdf-vm/asdf.sh" ]]; then
+ ASDF_DIR="/opt/asdf-vm"
+ ASDF_COMPLETIONS="$ASDF_DIR"
+fi
+
# If not found, check for Homebrew package
if [[ ! -f "$ASDF_DIR/asdf.sh" || ! -f "$ASDF_COMPLETIONS/asdf.bash" ]] && (( $+commands[brew] )); then
brew_prefix="$(brew --prefix asdf)"