Skip to content
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

If curl is not installed and bitsadmin not available due to access rights no download happens #14

Open
cheapsolutionarchitect opened this issue Mar 3, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@cheapsolutionarchitect
Copy link

Hi,

This is more an improvement instead of an issue. I've run into the following situation due to a highly outated millw.bat used by metals. See https://github.com/scalameta/metals/blob/17ed475be308ef3f914a806af00d32e8fc39cff2/metals/src/main/resources/millw.bat. As you can see only bitsadmin is tried for fetching the correct data file. In your version you are trying curl first. Now I'm in the situation that curl is not available and bitsadmin can only be run as administrator or from an elevated shell. However, Powershell runs and if I replace the bitsadmin call from the very outdated file with powershell "Import-Module BitsTransfer; Start-BitsTransfer 'https://github.com/lihaoyi/mill/releases/download/!MILL_BASE_VERSION!/!MILL_VERSION!!DOWNLOAD_SUFFIX!' '!DOWNLOAD_FILE!'" it works. So you might consider a third path that tries the powershell variant before resorting to the bitsadmin version.

@tgodzik
Copy link

tgodzik commented Mar 4, 2021

The scripts are highly outdated 😨 Updating them here: scalameta/metals#2579

@lefou lefou added the enhancement New feature or request label Mar 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants