Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(run): yarn run should never prompt when non-interactive (#5694)
**Summary** This pr fixes a bug ([#5655](#5655)) in which `yarn run --non-interactive` prints a `Error: No command specified` message and also suppresses the message `question Which command would you like to run?:` when running non-interactively. **Test plan** ``` > yarn-local run --non-interactive yarn run v1.6.0 info Commands available from binary scripts: acorn, atob, babylon, browserslist, commitizen, detect-libc, errno, escodegen, esgenerate, eslint, esparse, esvalidate, flow, git-cz, git-release-notes, gulp, gunzip-maybe, handlebars, import-local-fixture, jest, jest-runtime, js-yaml, jsesc, jsinspect, json5, loose-envify, miller-rabin, mkdirp, node-pre-gyp, nopt, prettier, rc, regjsparser, rimraf, sane, semver, sha.js, shjs, sshpk-conv, sshpk-sign, sshpk-verify, strip-indent, strip-json-comments, uglifyjs, user-home, uuid, watch, webpack, which info Project commands - build gulp build - build-bundle node ./scripts/build-webpack.js - build-chocolatey powershell ./scripts/build-chocolatey.ps1 - build-deb ./scripts/build-deb.sh - build-dist bash ./scripts/build-dist.sh - build-win-installer scripts\build-windows-installer.bat - changelog git-release-notes $(git describe --tags --abbrev=0 $(git describe --tags --abbrev=0)^)..$(git describe --tags --abbrev=0) scripts/changelog.md - commit git-cz - dupe-check yarn jsinspect ./src - lint eslint . && flow check - pkg-tests yarn --cwd packages/pkg-tests jest yarn.test.js - prettier eslint src __tests__ --fix - release-branch ./scripts/release-branch.sh - test yarn lint && yarn test-only - test-coverage node --max_old_space_size=4096 node_modules/jest/bin/jest.js --coverage --verbose - test-only node --max_old_space_size=4096 node_modules/jest/bin/jest.js --verbose - watch gulp watch ✨ Done in 0.28s. ```
- Loading branch information