node-build icon indicating copy to clipboard operation
node-build copied to clipboard

'latest' build definitions

Open jasonkarns opened this issue 9 years ago • 6 comments
trafficstars

Should we have some 'latest' build definitions that are always pointing to latest releases? The nodejs distributions list includes:

image

We could just have some build definitions that point to those locations, though that would mean the local install name of those nodes would be node-latest or node-latest-v5.x; since the version name would be taken from the build definition and not "updated" after installation to reflect the actual version number.

Alternatively, we could try some kind of after-install hook to rename the version once it's installed.

Is this a good or bad idea? It seems the rbenv team have avoided this for a long time. Presumably they have reason? nvm has similar aliases like node which points to latest release and 5.0 which is latest 5.x release.

jasonkarns avatar Apr 06 '16 17:04 jasonkarns

👌 this would be great for automating dev machine setup. I have to imagine 90% of installs are "whatever latest LTS is"

searls avatar Dec 22 '16 19:12 searls

Yeah, came here to effectively post the same thing — to be clear, it's a terrible idea to have it installed as “latest”, so this definitely needs the same thing that #159 brought up, by the way.

Previously, on nvm, I could simply “nvm install latest” or “nvm install stable” or “nvm install nightly”, and it would do the obvious thing — and better yet, on a new-ish machine, I could nvm install v8 and nvm install v6 to install the latest of each of those releases.

tl;dr seems to me nodenv / node-build is sorely missing install aliases — arguments you pass to nodenv install that don't install precisely what you typed, but an intelligent interpretation thereof. (I wouldn't mind if this were locked behind a flag or something, for backwards compatibility — nodenv install -a/--approx v8, or something?)

ELLIOTTCABLE avatar Jul 22 '17 08:07 ELLIOTTCABLE

Just following-up on this — reinstalled Nodenv today, spent five minutes trying to figure out why nodenv install v8 or nodenv install latest wasn't working, and ended up finding my own response to this Issue. 🤣

Is this just blocked by the overall lack of implementation for aliasing? Or is this a wontfix / unwanted behaviour? (=

ELLIOTTCABLE avatar Oct 08 '17 20:10 ELLIOTTCABLE

It's definitely not wontfix. I wouldn't say it's blocked, but the implementation is not straightforward. I've attempted a handful of alternate approaches that each have some annoyances and downsides. I should have some time soon to wrap it up, though.

jasonkarns avatar Oct 10 '17 16:10 jasonkarns

bump :)

shaharmor avatar Mar 17 '19 12:03 shaharmor

asdf uses node-build. It would be great if this would work

$ asdf install nodejs latest-lts
Trying to update node-build... ok
node-build: definition not found: latest-lts

gianpaj avatar Mar 03 '23 15:03 gianpaj