New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
What is a shim? #1135
Comments
@bestlem Thanks for the suggestion! We'll definitely look at updating the docs to improve the description. In the short-term, "shim" here refers to an executable that sits between the command you type and the program you run. For Volta, we install a set of binaries (really they're all symlinks to the same binary, So when you run e.g. Does that help clarify the comment in the docs? Happy to dig in more if you have follow-up questions! |
@charlespierce Yes thanks for that. I now understand and adding the second paragraph to the documentation as the main part and the first as detail would be good. (The second is the explanation the first and the idea of a him is just detail) Also the bit which I found really confusing is
I use conda for python which changes the PATH depending on the environment that it uses. Also many command line tools where you choose which version to use by py putting the directory to the specific directory it is in in your PATH. The wording "it adds a shim to your PATH" made me think volta did the same and altered the PATH to change the route to an executable. From your explanation PATH has nothing to do with the router. The shim executable is the thing that changes the route and you have to add the shim executable to the PATH, |
Installing a new tool does add a shim to your PATH resolution, but not by modifying the PATH directly. The Volta installer updates your shell profile script ( |
The way I read that was it altered the PATH each rime you changed the node (or npm) version. Whilst the PATH only needs to be chnaged on installing volta |
Ahh, yeah, I can see how that line could read that way. I'll take a look and see if there's a more precise way we could describe how Volta works. |
Linking to Wikipedia may help: https://en.wikipedia.org/wiki/Shim_(computing) |
@shamrin Yes that might give an overview but I think better to make the documentation describe how this particular project works. |
How to automatically switch environments after switching directories? |
The getting started document says
Volta does not use any fancy OS features or shell-specific hooks. It’s built on the simple, proven approach of shims.
That tells me nothing as I have never heard of shims. (I have been a Unix developer for 30 years so I will be able to understand what it does - as I don't know Rust I can't just read the code to see what it does)
Can you add to the documentation and explanation of what volta does.
The text was updated successfully, but these errors were encountered: