Skip to main content

Installing node & npm : Ubuntu 18.04 LTS

$ curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -

## Installing the NodeSource Node.js 10.x repo...


## Populating apt-get cache...

+ apt-get update
Hit:1 http://ph.archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://packages.microsoft.com/repos/vscode stable InRelease              
Get:3 http://ph.archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]  
Get:4 http://ph.archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]
Get:5 http://ph.archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [887 kB]
Hit:6 http://ppa.launchpad.net/inkscape.dev/stable/ubuntu bionic InRelease    
Hit:7 http://security.ubuntu.com/ubuntu bionic-security InRelease              
Fetched 1,051 kB in 2s (443 kB/s)                          
Reading package lists... Done

## Confirming "bionic" is supported...

+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_10.x/dists/bionic/Release'

## Adding the NodeSource signing key to your keyring...

+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -
OK

## Creating apt sources list file for the NodeSource Node.js 10.x repo...

+ echo 'deb https://deb.nodesource.com/node_10.x bionic main' > /etc/apt/sources.list.d/nodesource.list
+ echo 'deb-src https://deb.nodesource.com/node_10.x bionic main' >> /etc/apt/sources.list.d/nodesource.list

## Running `apt-get update` for you...

+ apt-get update
Hit:1 http://ph.archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://packages.microsoft.com/repos/vscode stable InRelease              
Hit:3 http://ph.archive.ubuntu.com/ubuntu bionic-updates InRelease            
Get:4 http://ph.archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]
Hit:5 http://security.ubuntu.com/ubuntu bionic-security InRelease              
Get:6 https://deb.nodesource.com/node_10.x bionic InRelease [4,584 B]          
Hit:7 http://ppa.launchpad.net/inkscape.dev/stable/ubuntu bionic InRelease    
Get:8 https://deb.nodesource.com/node_10.x bionic/main amd64 Packages [765 B]  
Fetched 79.9 kB in 1s (54.2 kB/s)
Reading package lists... Done

## Run `sudo apt-get install -y nodejs` to install Node.js 10.x and npm
## You may also need development tools to build native addons:
     sudo apt-get install gcc g++ make
## To install the Yarn package manager, run:
     curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
     echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
     sudo apt-get update && sudo apt-get install yarn


$ sudo apt install nodejs
Reading package lists... Done
Building dependency tree      
Reading state information... Done
The following NEW packages will be installed:
  nodejs
0 upgraded, 1 newly installed, 0 to remove and 19 not upgraded.
Need to get 16.2 MB of archives.
After this operation, 81.1 MB of additional disk space will be used.
Get:1 https://deb.nodesource.com/node_10.x bionic/main amd64 nodejs amd64 10.19.0-1nodesource1 [16.2 MB]
Fetched 16.2 MB in 21s (787 kB/s)                                              
Selecting previously unselected package nodejs.
(Reading database ... 170910 files and directories currently installed.)
Preparing to unpack .../nodejs_10.19.0-1nodesource1_amd64.deb ...
Unpacking nodejs (10.19.0-1nodesource1) ...
Setting up nodejs (10.19.0-1nodesource1) ...
Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
bboycan@bboy-Latitude-E7450:~$ node -v
v10.19.0
$ npm -v
6.13.4

Comments

Popular posts from this blog

Ubuntu 16.04 LT - Installing Chromium browser

> Type these commands about this PPA : $ sudo add-apt-repository ppa:canonical-chromium-builds/stage $ sudo apt-get update $ sudo apt-get install chromium-browser > Terminal: mccrazy@Lenovo-N22:~$ sudo add-apt-repository ppa:canonical-chromium-builds/stage [sudo] password for mccrazy:  Testing site just before upload to Ubuntu main. Things here are either broken and not ready to use, or landing in the distro anyway very soon. You shouldn't use this.  More info: https://launchpad.net/~canonical-chromium-builds/+archive/ubuntu/stage Press [ENTER] to continue or ctrl-c to cancel adding it gpg: keyring `/tmp/tmp6cfppy_r/secring.gpg' created gpg: keyring `/tmp/tmp6cfppy_r/pubring.gpg' created gpg: requesting key 5B393194 from hkp server keyserver.ubuntu.com gpg: /tmp/tmp6cfppy_r/trustdb.gpg: trustdb created gpg: key 5B393194: public key "Launchpad PPA for Canonical Chromium Build Team" imported gpg: Total number processed: 1 gpg:               imported: 1  (RSA...

Ubuntu 20.04 LTS | Installing OpenJDK 11 (LTS) JDK, JRE, HotSpot

https://adoptopenjdk.net/installation.html#linux-pkg ctrl + f => Linux RPM and DEB installer packages bboy@bboy-LE7450:~$ cat /etc/os-release | grep UBUNTU_CODENAME UBUNTU_CODENAME=focal bboy@bboy-LE7450:~$ sudo apt-get install wget apt-transport-https gnupg [sudo] password for bboy: Reading package lists... Done Building dependency tree       Reading state information... Done wget is already the newest version (1.20.3-1ubuntu1). wget set to manually installed. gnupg is already the newest version (2.2.19-3ubuntu2.1). gnupg set to manually installed. The following packages were automatically installed and are no longer required:   linux-headers-5.8.0-45-generic linux-hwe-5.8-headers-5.8.0-45   linux-image-5.8.0-45-generic linux-modules-5.8.0-45-generic   linux-modules-extra-5.8.0-45-generic Use 'sudo apt autoremove' to remove them. The following NEW packages will be installed:   apt-transport-https 0 upgraded, 1 newly installed, 0 to remove and 21 not upgraded. Need to get 1,...