Skip to content

Install Yarn #163

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

Install Yarn #163

wants to merge 1 commit into from

Conversation

yahonda
Copy link
Member

@yahonda yahonda commented Nov 4, 2018

This pull request installs yarn 1.12.1 to support Rails 6 Webpacker.

Installation guide:

https://yarnpkg.com/en/docs/install#debian-stable

Steps to reproduce:

> vagrant up
> vagrant ssh
$ git clone https://github.com/rails/rails.git
$ cd railties
$ bundle install
$ bundle exec rake test

Actual result without this pull request:

vagrant@rails-dev-box:~/rails/railties$ bundle exec rake test
rake aborted!
Errno::ENOENT: No such file or directory - yarn
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:478:in ``'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:478:in `block (2 levels) in <top (required)>'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:477:in `chdir'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:477:in `block in <top (required)>'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:470:in `initialize'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:470:in `new'
/home/vagrant/rails/railties/test/isolation/abstract_unit.rb:470:in `<top (required)>'
/home/vagrant/rails/railties/Rakefile:32:in `require_relative'
/home/vagrant/rails/railties/Rakefile:32:in `block (2 levels) in <top (required)>'
Tasks: TOP => test => test:isolated
(See full trace by running task with --trace)
vagrant@rails-dev-box:~/rails/railties$ pwd
/home/vagrant/rails/railties
vagrant@rails-dev-box:~/rails/railties$

Note:

yarn pkg available from the Ubuntu distribution is version 0.32, which does not satisfy the Webpacker requirement.

$ bundle exec rake test
00h00m00s 0/0: : ERROR: [Errno 2] No such file or directory: 'build'
Webpacker requires Yarn >= 1.0.0 and you are using 0.32
Please upgrade Yarn https://yarnpkg.com/lang/en/docs/install/
00h00m00s 0/0: : ERROR: [Errno 2] No such file or directory: 'add'
Usage: yarn [options]

yarn: error: no such option: --tilde

Installed yarn version by this pull request:

$  yarn -v
1.12.1

yarn available from the Ubuntu distribution
is version 0.32, which does not require Webpacker requirement.

> Webpacker requires Yarn >= 1.0.0 and you are using 0.32

It instals version 1.12 following the installation guide below.
https://yarnpkg.com/en/docs/install#debian-stable
@yahonda
Copy link
Member Author

yahonda commented Jan 23, 2019

Closed via 2c1c2d5

@yahonda yahonda closed this Jan 24, 2019
@fxn
Copy link
Member

fxn commented Jan 24, 2019

Oh sorry! I missed this PR and noticed Yarn was missing yesterday while testing some stuff. Thanks for the patch anyway ❤️.

@yahonda yahonda deleted the install_yarn branch April 25, 2019 08:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants