Installing a specifc node version on both Windows and Linux Builds
I am trying to install node version 10.3.0 in both the windows and linux image however the following fails on the linux image with "Install-Product : The term 'Install-Product' is not recognized as the name of a cmdlet, function, script file, or operable program."
image:
- Ubuntu
- Visual Studio 2017
# Test against the latest version of this Node.js version
environment:
nodejs_version: "10.3.0"
# Install scripts. (runs after repo cloning)
install:
# Get the latest stable version of Node.js or io.js
- ps: Install-Product node $env:nodejs_version
How can I install a specific version of node in bother images
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Ilya Finkelshte... on 03 Jul, 2018 06:12 PM
Sorry for confusion.
Install-Product
is for Windows only. For Ubuntu please usenvm
or our new language stack construct. To run different configurations for Linux and Windows side-by-side, please check this part of doc.For example, this is one of the options to express this in YAML, for me it is quite simple and compact:
Ilya Finkelshteyn closed this discussion on 03 Sep, 2018 09:00 PM.