website icon indicating copy to clipboard operation
website copied to clipboard

yarn install script has issues when running in dash

Open interone-ms opened this issue 4 years ago • 1 comments

Bug description

When running the yarn install.sh script in a system set with dash as sh shell, there are errors during installation displayed, as the installation script uses bashisms.

Command

./install.sh

What is the current behavior?

install.sh outputs warnings:

install.sh: 52: [[: not found
install.sh: 57: [: unexpected operator
install.sh: 95: [[: not found

What is the expected behavior? The installer should run without warnings.

Steps to Reproduce

  1. curl -L -o install.sh https://yarnpkg.com/install.sh
  2. chmod +x install.sh && ./install.sh

Environment

  • Node Version: n/a
  • Yarn v1 Version: 1.19.2
  • OS and version: any os with dash shell

interone-ms avatar Feb 05 '20 15:02 interone-ms

Would you like to submit a PR to fix this?

Daniel15 avatar Feb 05 '20 19:02 Daniel15