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

Re-use source file / tarball, etc. #1193

Closed
PeterDaveHello opened this issue Aug 5, 2016 · 8 comments
Closed

Re-use source file / tarball, etc. #1193

PeterDaveHello opened this issue Aug 5, 2016 · 8 comments
Assignees
Labels
feature requests I want a new feature in nvm! pull request wanted This is a great way to contribute! Help us out :-D

Comments

@PeterDaveHello
Copy link
Collaborator

Can we just download the checksums to verify (if there is) the existing tarball / source file before re-downloading instead of force re-download the files?

The size of nodejs v6.3.1 src tarball is 25MB, the 64-bit binary is 8.7MB, we could save the bandwidth and time.

@ljharb ljharb added the feature requests I want a new feature in nvm! label Aug 5, 2016
@ljharb
Copy link
Member

ljharb commented Aug 5, 2016

The problem there is that not every system nvm supports is able to compute SHA256 checksums - so we'd only be able to do that when the ability to compute checksums exists.

I'd definitely take a PR that added this, though - that would allow travis-ci builds to cache $NVM_DIR and greatly speed up test runs.

@ljharb ljharb added the pull request wanted This is a great way to contribute! Help us out :-D label Aug 5, 2016
@PeterDaveHello
Copy link
Collaborator Author

@ljharb in the meantime, maybe SHA1 first? Or those platforms also don't support SHA1? Since there is https, for the weaker hash, the checksum we can just use to make sure the process or downloading is good, not for the integrity, what do you think?

@ljharb
Copy link
Member

ljharb commented Aug 6, 2016

SHA1 is no longer used by node as of v4, as you can see here.

In other words, we can definitely make it work with node 0.12 and older, and possibly some iojs versions, with SHA-1, and that would be a great start.

@PeterDaveHello
Copy link
Collaborator Author

@ljharb I'm not sure if it's a bad idea that bad enough to ignore it, what about we maintain a sha1 list by ourselves? If you won't hate it, we can try to do it automatically.

@ljharb
Copy link
Member

ljharb commented Aug 17, 2016

I definitely don't want to maintain my own list of anything; we already have enough runtime internet dependencies as it is, and the SHAs of old versions might change and would need to be kept up to date.

I'm already working on this; I'm just trying to get some tests passing.

@ljharb ljharb self-assigned this Aug 17, 2016
@PeterDaveHello
Copy link
Collaborator Author

Nice, any PR / branch that I can look into? Thanks.

@ljharb
Copy link
Member

ljharb commented Aug 18, 2016

Nothing quite yet. I'll update here when it's ready.

@tiramgear
Copy link

GOOD

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature requests I want a new feature in nvm! pull request wanted This is a great way to contribute! Help us out :-D
Projects
None yet
Development

No branches or pull requests

3 participants