volta icon indicating copy to clipboard operation
volta copied to clipboard

Support for scoop on Windows

Open MikeVensel opened this issue 4 years ago • 6 comments

Would you consider adding support for installing Volta via scoop on Windows?

MikeVensel avatar May 23 '20 15:05 MikeVensel

@MikeVensel Definitely! If I'm reading the docs correctly, we'll need to make a manifest file publicly available so people can install it directly. We can publish on GitHub, or, to make things even simpler, we may be able to use get.volta.sh/scoop (we'll have to look at the netlify redirect settings).

charlespierce avatar May 25 '20 17:05 charlespierce

I've implemented this in my scoop bucket, you can install volta via scoop with the following steps:

# subscribe to my bucket
scoop bucket add dorado https://github.com/chawyehsu/dorado
# install
scoop install dorado/volta
# update
scoop update volta

The manifest is located in here and you can investigate if you want to know the detail. I did some tricks to make shims upgrade work with scoop's data persistence. Maybe there would be a better way to update shims.

chawyehsu avatar Jul 28 '20 08:07 chawyehsu

@chawyehsu I'm sorry but I don't quite understand the installer script in the app manifest, are you copying volta-shim.exe to be node.exe/npm.exe/npx.exe/yarn.exe?

If I understand it correctly, you're actually trying to do the following:

UpdateExeFile 'node.exe' 'node.exe'
UpdateExeFile 'npm.exe' 'npm.exe'
UpdateExeFile 'npx.exe' 'npx.exe'
UpdateExeFile 'yarn.exe' 'yarn.exe'

Please point out if I miss anything...

athrunsun avatar Jan 19 '21 15:01 athrunsun

@athrunsun

are you copying volta-shim.exe to be node.exe/npm.exe/npx.exe/yarn.exe?

If I understand it correctly, you're actually trying to do the following:

UpdateExeFile 'node.exe' 'node.exe'
UpdateExeFile 'npm.exe' 'npm.exe'
UpdateExeFile 'npx.exe' 'npx.exe'
UpdateExeFile 'yarn.exe' 'yarn.exe'

Please point out if I miss anything...

You're right, it does make volta-shim.exe copies to be node/npm/npx/yarn. This is a simulation (or reproduction) of what the volta installer does. The volta installer creates shims of those four executables with volta-shim.exe while the installation. You could read here and here for the detail.

chawyehsu avatar Jan 19 '21 15:01 chawyehsu

~An update: When I tried to use scoop to install volta, today, the resulting volta command would always do nothing, every time it was run.~

davidbludlow avatar Apr 13 '22 00:04 davidbludlow

I was wrong. The reason that that didn't work for me was because I didn't have Developer Mode for Windows enabled, so the simlinks couldn't be created.

davidbludlow avatar Apr 26 '22 18:04 davidbludlow

Looks like this has been resolved. Marking it as closed accordingly!

chriskrycho avatar Dec 20 '23 00:12 chriskrycho