To install NVM on Ubuntu 24.04, follow the steps below.
Step 1 : Ensure your package index is up-to-date:
Step 2 : Install the required packages for building NVM and Node.js:
Step 3 : Download and install the NVM installation script using curl:
Step 4 : Source the bash profile to load NVM environment variables:
Step 5 : Verify that NVM is installed correctly by checking its version:
Step 6 : Basic NVM Usage
- Install a specific version of Node.js:
- Use a specific version of Node.js:
- Set a default Node.js version:
- Check the version of Node.js in use:
- List installed Node.js versions:
Congratulations! You have successfully installed NVM on Ubuntu 24.04.