Installing yarnpkg on Debian 11 (bullseye)

To install (currently installs version 1.22.10):

mkdir -p ~/src/yarn
cd ~/src/yarn
sudo apt install npm
npm install yarn
sudo ln -s "$PWD/node_modules/yarn/bin/yarnpkg" /usr/bin/yarnpkg

You should check that the SHA256 reported of the cli.js file is the same as the file dowloaded from

sha256sum cli.js node_modules/yarn/lib/cli.js 
defb0fe75a912a939852526658f6e7c09171c773f384e6add1c92a13112e0d0e cli.js
defb0fe75a912a939852526658f6e7c09171c773f384e6add1c92a13112e0d0e node_modules/yarn/lib/cli.js
rm cli.js

To upgrade:

cd ~/src/yarn
yarnpkg upgrade
This entry was posted in Howtos, Uncategorized. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *