-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Use homebrew-versions to install an old version of yarn #1882
Comments
I ran into this today and I do not have the previous version of yarn already installed via brew. So now I am a bit stuck. |
yarn (0.23.2) isn't tied to the node version, it will run whatever version of node your terminal environment has declared My solution:
|
I would love to see this fixed. If I may rephrase the problem:
As a work around it's still possible to do the following, but it involves curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version [version] |
Yeah running into the same issue as @mysterycommand - your recommendation is what I've been using for a while now. |
The recommend solution in this StackOverflow answer fixed it well enough for my script to proceed, but I'm not sure what side effects it has. It certainly doesn't enable a
|
@mysterycommand the install script doesn't. It references an invalid URL that doesn't exist.
|
|
Here's the solution to anyone wanting to use homebrew for different versions of yarn - or any formula for that matter.
You can then verify the versions available to Homebrew by running: |
Using a CI tool that is locked to Yarn 1.13.0. Used this command. brew uninstall yarn && curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.13.0 In effect, I don't have yarn managed by brew anymore. But I still added it to my path using the following: echo 'export PATH=$PATH:~/.yarn/bin/yarn' >> ~/.bash_profile
source ~/.bash_profile Good enough for me. But having it managed by brew seems preferable. |
Do you want to request a feature or report a bug?
feature
What is the current behavior?
I use yarn 0.16.1, and want to update a dev dep. But yarn does not properly update the
package.json
file.So I search around and found #1458. In this issue, it said the latest yarn has fix the problem. So I use brew to update to yarn 0.17.2 but encounter another problem similar like this #1834.
What is the expected behavior?
The first thing came into my mind is that I need to downgrade yarn to a working version. Then I found this question on stackoverflow.
Luck for me, I still have the old version installed. So I can easily switch to an old version use
brew switch yarn 0.16.1
. But what if someone have only installed the newest version of yarn and it does not work. So I think it would be nice if we can install an old version through homebrew-versions. But I am not very familiar with brew. So is there anyone who can write some formulas and upload to homebrew-versions.The text was updated successfully, but these errors were encountered: