asdf-vm / asdf

Extendable version manager with support for Ruby, Node.js, Elixir, Erlang & more
https://asdf-vm.com/
MIT License
21.13k stars 763 forks source link

bug: ASDF_DEBUG: unbound variable #1743

Open ncapilla opened 2 months ago

ncapilla commented 2 months ago

Describe the Bug

If you run a script with set -u, it will raise this error because you are accessing the variable without checking if it's set or not.

/root/.asdf/bin/asdf: line 4: ASDF_DEBUG: unbound variable

Steps to Reproduce

Using v0.14.0, run a script with set -u and try to use asdf.

Expected Behaviour

The access to the env variable is controlled.

Actual Behaviour

It raises an error.

Environment

Not needed

asdf plugins affected (if relevant)

No response

ncapilla commented 2 months ago

Same here

/root/.asdf/lib/utils.bash: line 30: ASDF_DATA_DIR: unbound variable