Open devinrhode2 opened 1 year ago
Our docs do warn that depending on your setup you may need sudo
. I don't believe we should add a new command for this type of situation, asdf doctor
. Supporting all permutations of people's setups is difficult, though we can guard against bad states.
When in this state, what does running asdf reshim
do? Does it error? It may be that the error is being masked when it is called during install:
https://github.com/asdf-vm/asdf/blob/5af76257693d1f560b9c27c9cdcc6f5a5a33c4d5/lib/functions/installs.bash#L232
Idk what reshim would do
I'm using the git install method now
On Tue, Dec 20, 2022, 8:35 PM James Hegedus @.***> wrote:
Our docs do warn that depending on your setup you may need sudo. I don't believe we should add a new command for this type of situation, asdf doctor.
When in this state, what does running asdf reshim do? Does it error? It may be that the error is being masked when it is called during install:
— Reply to this email directly, view it on GitHub https://github.com/asdf-vm/asdf/issues/1387#issuecomment-1360650237, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAEDZKGL4PG7CIRFUQDANXLWOJNERANCNFSM6AAAAAATE6FFX4 . You are receiving this because you authored the thread.Message ID: @.***>
Reshim would attempt to recreate the shims, so if your speculation is correct that the shims couldn't have be created then perhaps reshim
would surface the issue and we would A) confirm the source of the problem and B) be let us to dig into how the problem is being masked. As it is, we have little information.
The codebase currently does perform checks and even has a rollback mechanism in the install
code paths.
The core team do not use the community created Homebrew package which causes a lot of issues for users. So unless you have the time to create a failing test case in our test suite, we will have a hard time emulating the specific scenario and remediating any errors within the codebase.
Does asdf currently have a mechanism for informing users of new releases when they are running commands?
If it does, mentioning this in docs would be a good idea, after "We highly recommend using the official git method."
It might also help to include some rationale.
Does asdf currently have a mechanism for informing users of new releases when they are running commands?
It does not, though this is planned.
Does asdf currently have a mechanism for informing users of new releases when they are running commands?
If it does, mentioning this in docs would be a good idea, after "We highly recommend using the official git method."
It might also help to include some rationale.
- Nobody on core team uses homebrew
- Using homebrew introduces an additional layer of complexity where things can fail, particularly for a tool like asdf, because it also makes a lot of changes to system binaries.
Thanks very much for the explanation @devinrhode2 - homebrew is seemingly an easier way of installing (as it manages the dependencies) and it doesn't look like anything will break if you just use homebrew (why would they add that installation method to the official readme if it doesn't work?!) - so this extra context is useful. If you have time, it might be nice to add that explanation to the docs. Cheers regardless!
Describe the Bug
Steps to Reproduce
Install homebrew without
sudo
(see my homebrew prefix at bottom of logs above) Install asdf via homebrew Install node via asdf Runnode
node is not definedExpected Behaviour
node should be defined. Some earlier process probably should have failed.
Which step should have failed will depend on where the actual problem exists.
I suppose each step should do some basic checks to determine if things will be working correctly?
Or there could be a general-purpose
asdf doctor
command, similar to homebrew.If asdf installs but can't hook into shell executables..
Maybe after adding the nodejs plugin, asdf checks if it can add a
node
shim successfully. If it can't, it uninstalls the nodejs plugin. Or, it does this check before installing the nodejs plugin.If you tried to install asdf on a windows 95 machine, it should probably fail right away, saying that your platform is not supported.
Actual Behaviour
node is not defined
Environment
asdf plugins affected (if relevant)
nodejs?