How To Install Yarn On Linux Mint 20.2
- 00:30 cat /etc/os-release
- 00:56 curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
- 01:10 echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
- 01:30 sudo apt-get update && sudo apt-get install yarn
- 02:00 curl -o- -L https://yarnpkg.com/install.sh | bash
- 02:20 yarn -v
To Install Yarn On Linux Mint 20.2
Introduction :
Yarn is a package manager for your code. It allows you to use and share (e.g. JavaScript) code with other developers from around the world. ... Yarn allows you to use other developers' solutions to different problems, making it easier for you to develop your software.
Installation procedure :
Step 1 : Check the OS version by using the below command
root@linuxhelp:~# cat /etc/os-release
NAME="Linux Mint"
VERSION="20.2 (Uma)"
ID=linuxmint
ID_LIKE=ubuntu
PRETTY_NAME="Linux Mint 20.2"
VERSION_ID="20.2"
HOME_URL="https://www.linuxmint.com/"
SUPPORT_URL="https://forums.linuxmint.com/"
BUG_REPORT_URL="http://linuxmint-troubleshooting-guide.readthedocs.io/en/latest/"
PRIVACY_POLICY_URL="https://www.linuxmint.com/"
VERSION_CODENAME=uma
UBUNTU_CODENAME=focal
Step 2 : Add the gpg key y using the below command
root@linuxhelp:~# curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
OK
Step 3 : Update the source list by using the below command
root@linuxhelp:~# echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
deb https://dl.yarnpkg.com/debian/ stable main
Step 4 : Update and install yarn y using the below command
root@linuxhelp:~# apt-get update && apt-get install yarn
Get:1 https://dl.yarnpkg.com/debian stable InRelease [17.1 kB]
Get:2 https://dl.yarnpkg.com/debian stable/main all Packages [10.5 kB]
Hit:7 http://security.ubuntu.com/ubuntu focal-security InRelease
Hit:8 http://packages.linuxmint.com uma Release
Hit:9 http://archive.ubuntu.com/ubuntu focal InRelease
Hit:11 http://archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:12 http://archive.ubuntu.com/ubuntu focal-backports InRelease
Fetched 48.7 kB in 1s (36.1 kB/s)
Reading package lists... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libnode64 nodejs nodejs-doc
Step 5 : Install the yarn package y using the below URL
root@linuxhelp:~# curl -o- -L https://yarnpkg.com/install.sh | bash
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 53 100 53 0 0 234 0 --:--:-- --:--:-- --:--:-- 234
100 7152 100 7152 0 0 15928 0 --:--:-- --:--:-- --:--:-- 96648
Installing Yarn!
> Downloading tarball...
> GPG signature looks good
> Extracting to ~/.yarn...
> Adding to $PATH...
> We've added the following to your /root/.bashrc
> If this isn't the profile of your current shell then please add the following to your correct profile:
export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
> Successfully installed Yarn 1.22.17! Please open another terminal where the `yarn` command will now be available.
Step 6 : Check the version of yarn by using the below command
root@linuxhelp:~# yarn -v
1.22.17
With this, the process of installing yarn on linux mint 20.2 has come to an end.
Comments ( 0 )
No comments available