Ubuntu 14.04 LTSにYarnをインストール
前提
Ubuntu: 14.04 LTS
参考
https://yarnpkg.com/en/docs/install#linux-tab
インストール
公式の手順どおりにコマンドを実行
$ curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - OK $ 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 $ sudo apt-get update && sudo apt-get install yarn Get:1 https://dl.yarnpkg.com stable InRelease Get:2 https://dl.yarnpkg.com stable/main amd64 Packages Ign http://us.archive.ubuntu.com trusty InRelease Ign http://apt.puppetlabs.com trusty InRelease Get:3 http://security.ubuntu.com trusty-security InRelease [65.9 kB] Get:4 http://us.archive.ubuntu.com trusty-updates InRelease [65.9 kB] Get:5 https://dl.yarnpkg.com stable/main i386 Packages Get:6 http://apt.puppetlabs.com trusty Release.gpg [836 B] Get:7 https://dl.yarnpkg.com stable/main Translation-en_US Get:8 https://dl.yarnpkg.com stable/main Translation-en_US Get:9 https://dl.yarnpkg.com stable/main Translation-en_US Get:10 https://dl.yarnpkg.com stable/main Translation-en_US Get:11 https://dl.yarnpkg.com stable/main Translation-en_US Get:12 https://dl.yarnpkg.com stable/main Translation-en_US Get:13 https://dl.yarnpkg.com stable/main Translation-en_US Get:14 https://dl.yarnpkg.com stable/main Translation-en_US Get:15 https://dl.yarnpkg.com stable/main Translation-en Get:16 https://dl.yarnpkg.com stable/main Translation-en Get:17 https://dl.yarnpkg.com stable/main Translation-en Get:18 https://dl.yarnpkg.com stable/main Translation-en Get:19 https://dl.yarnpkg.com stable/main Translation-en Get:20 https://dl.yarnpkg.com stable/main Translation-en Get:21 https://dl.yarnpkg.com stable/main Translation-en Get:22 https://dl.yarnpkg.com stable/main Translation-en Get:23 http://apt.puppetlabs.com trusty Release [54.2 kB] Get:24 https://dl.yarnpkg.com stable/main Translation-en_US Get:25 https://dl.yarnpkg.com stable/main Translation-en_US Get:26 https://dl.yarnpkg.com stable/main Translation-en_US Get:27 https://dl.yarnpkg.com stable/main Translation-en_US Get:28 https://dl.yarnpkg.com stable/main Translation-en_US Get:29 https://dl.yarnpkg.com stable/main Translation-en_US Get:30 https://dl.yarnpkg.com stable/main Translation-en_US Get:31 https://dl.yarnpkg.com stable/main Translation-en Get:32 https://dl.yarnpkg.com stable/main Translation-en Get:33 https://dl.yarnpkg.com stable/main Translation-en Get:34 http://us.archive.ubuntu.com trusty-backports InRelease [65.9 kB] Err http://apt.puppetlabs.com trusty Release Get:35 https://dl.yarnpkg.com stable/main Translation-en_US Get:36 https://dl.yarnpkg.com stable/main Translation-en_US Get:37 https://dl.yarnpkg.com stable/main Translation-en_US Get:38 https://dl.yarnpkg.com stable/main Translation-en Get:39 https://dl.yarnpkg.com stable/main Translation-en Get:40 https://dl.yarnpkg.com stable/main Translation-en Hit http://us.archive.ubuntu.com trusty Release.gpg Get:41 http://security.ubuntu.com trusty-security/main Sources [129 kB] Get:42 https://dl.yarnpkg.com stable/main Translation-en_US Get:43 https://dl.yarnpkg.com stable/main Translation-en_US Get:44 https://dl.yarnpkg.com stable/main Translation-en_US Get:45 https://dl.yarnpkg.com stable/main Translation-en Get:46 https://dl.yarnpkg.com stable/main Translation-en Get:47 https://dl.yarnpkg.com stable/main Translation-en Get:48 http://us.archive.ubuntu.com trusty-updates/main Sources [395 kB] Get:49 https://dl.yarnpkg.com stable/main Translation-en_US Get:50 https://dl.yarnpkg.com stable/main Translation-en_US Get:51 https://dl.yarnpkg.com stable/main Translation-en_US Ign https://dl.yarnpkg.com stable/main Translation-en_US Get:52 https://dl.yarnpkg.com stable/main Translation-en Get:53 https://dl.yarnpkg.com stable/main Translation-en Get:54 https://dl.yarnpkg.com stable/main Translation-en Ign https://dl.yarnpkg.com stable/main Translation-en Get:55 http://security.ubuntu.com trusty-security/restricted Sources [4,941 B] Get:56 http://us.archive.ubuntu.com trusty-updates/restricted Sources [6,327 B] Get:57 http://security.ubuntu.com trusty-security/universe Sources [51.2 kB] Get:58 http://us.archive.ubuntu.com trusty-updates/universe Sources [177 kB] Get:59 http://security.ubuntu.com trusty-security/multiverse Sources [3,196 B] Get:60 http://us.archive.ubuntu.com trusty-updates/multiverse Sources [7,759 B] Get:61 http://us.archive.ubuntu.com trusty-updates/main amd64 Packages [972 kB] Get:62 http://security.ubuntu.com trusty-security/main amd64 Packages [606 kB] Get:63 http://us.archive.ubuntu.com trusty-updates/restricted amd64 Packages [17.1 kB] Get:64 http://us.archive.ubuntu.com trusty-updates/universe amd64 Packages [403 kB] Get:65 http://security.ubuntu.com trusty-security/restricted amd64 Packages [14.0 kB] Get:66 http://us.archive.ubuntu.com trusty-updates/multiverse amd64 Packages [14.3 kB] Get:67 http://security.ubuntu.com trusty-security/universe amd64 Packages [155 kB] Get:68 http://us.archive.ubuntu.com trusty-updates/main i386 Packages [932 kB] Get:69 http://security.ubuntu.com trusty-security/multiverse amd64 Packages [4,135 B] Get:70 http://us.archive.ubuntu.com trusty-updates/restricted i386 Packages [16.9 kB] Get:71 http://security.ubuntu.com trusty-security/main i386 Packages [565 kB] Get:72 http://us.archive.ubuntu.com trusty-updates/universe i386 Packages [405 kB] Get:73 http://security.ubuntu.com trusty-security/restricted i386 Packages [13.8 kB] Get:74 http://us.archive.ubuntu.com trusty-updates/multiverse i386 Packages [14.6 kB] Get:75 http://security.ubuntu.com trusty-security/universe i386 Packages [156 kB] Get:76 http://us.archive.ubuntu.com trusty-updates/main Translation-en [482 kB] Get:77 http://security.ubuntu.com trusty-security/multiverse i386 Packages [4,288 B] Get:78 http://us.archive.ubuntu.com trusty-updates/multiverse Translation-en [7,430 B] Get:79 http://security.ubuntu.com trusty-security/main Translation-en [332 kB] Get:80 http://us.archive.ubuntu.com trusty-updates/restricted Translation-en [3,975 B] Get:81 http://security.ubuntu.com trusty-security/multiverse Translation-en [2,201 B] Get:82 http://us.archive.ubuntu.com trusty-updates/universe Translation-en [214 kB] Get:83 http://security.ubuntu.com trusty-security/restricted Translation-en [3,505 B] Get:84 http://us.archive.ubuntu.com trusty-backports/main Sources [9,712 B] Get:85 http://us.archive.ubuntu.com trusty-backports/restricted Sources [28 B] Get:86 http://security.ubuntu.com trusty-security/universe Translation-en [90.7 kB] Get:87 http://us.archive.ubuntu.com trusty-backports/universe Sources [35.3 kB] Get:88 http://us.archive.ubuntu.com trusty-backports/multiverse Sources [1,898 B] Get:89 http://us.archive.ubuntu.com trusty-backports/main amd64 Packages [13.3 kB] Get:90 http://us.archive.ubuntu.com trusty-backports/restricted amd64 Packages [28 B] Get:91 http://us.archive.ubuntu.com trusty-backports/universe amd64 Packages [43.2 kB] Get:92 http://us.archive.ubuntu.com trusty-backports/multiverse amd64 Packages [1,571 B] Get:93 http://us.archive.ubuntu.com trusty-backports/main i386 Packages [13.3 kB] Get:94 http://us.archive.ubuntu.com trusty-backports/restricted i386 Packages [28 B] Get:95 http://us.archive.ubuntu.com trusty-backports/universe i386 Packages [43.2 kB] Get:96 http://us.archive.ubuntu.com trusty-backports/multiverse i386 Packages [1,552 B] Get:97 http://us.archive.ubuntu.com trusty-backports/main Translation-en [7,503 B] Get:98 http://us.archive.ubuntu.com trusty-backports/multiverse Translation-en [1,215 B] Get:99 http://us.archive.ubuntu.com trusty-backports/restricted Translation-en [28 B] Get:100 http://us.archive.ubuntu.com trusty-backports/universe Translation-en [36.8 kB] Hit http://us.archive.ubuntu.com trusty Release Hit http://us.archive.ubuntu.com trusty/main Sources Hit http://us.archive.ubuntu.com trusty/restricted Sources Hit http://us.archive.ubuntu.com trusty/universe Sources Hit http://us.archive.ubuntu.com trusty/multiverse Sources Hit http://us.archive.ubuntu.com trusty/main amd64 Packages Hit http://us.archive.ubuntu.com trusty/restricted amd64 Packages Hit http://us.archive.ubuntu.com trusty/universe amd64 Packages Hit http://us.archive.ubuntu.com trusty/multiverse amd64 Packages Hit http://us.archive.ubuntu.com trusty/main i386 Packages Hit http://us.archive.ubuntu.com trusty/restricted i386 Packages Hit http://us.archive.ubuntu.com trusty/universe i386 Packages Hit http://us.archive.ubuntu.com trusty/multiverse i386 Packages Hit http://us.archive.ubuntu.com trusty/main Translation-en Hit http://us.archive.ubuntu.com trusty/multiverse Translation-en Hit http://us.archive.ubuntu.com trusty/restricted Translation-en Hit http://us.archive.ubuntu.com trusty/universe Translation-en Ign http://us.archive.ubuntu.com trusty/main Translation-en_US Ign http://us.archive.ubuntu.com trusty/multiverse Translation-en_US Ign http://us.archive.ubuntu.com trusty/restricted Translation-en_US Ign http://us.archive.ubuntu.com trusty/universe Translation-en_US Fetched 6,685 kB in 16s (414 kB/s) Reading package lists... Done W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://apt.puppetlabs.com trusty Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 7F438280EF8D349F W: Failed to fetch http://apt.puppetlabs.com/dists/trusty/Release W: Some index files failed to download. They have been ignored, or old ones used instead. Reading package lists... Done Building dependency tree Reading state information... Done Recommended packages: nodejs The following NEW packages will be installed: yarn 0 upgraded, 1 newly installed, 0 to remove and 245 not upgraded. Need to get 2,040 kB of archives. After this operation, 28.1 MB of additional disk space will be used. Get:1 https://dl.yarnpkg.com/debian/ stable/main yarn all 0.23.2-1 [2,040 kB] Fetched 2,040 kB in 0s (4,499 kB/s) Selecting previously unselected package yarn. (Reading database ... 88937 files and directories currently installed.) Preparing to unpack .../archives/yarn_0.23.2-1_all.deb ... Unpacking yarn (0.23.2-1) ... Setting up yarn (0.23.2-1) ...
確認
$ yarn --version 0.23.2