Skip to content
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

Default argumenst for yarn in package.json or .yarnrc #3282

Closed
wclr opened this issue Apr 29, 2017 · 9 comments
Closed

Default argumenst for yarn in package.json or .yarnrc #3282

wclr opened this issue Apr 29, 2017 · 9 comments
Labels

Comments

@wclr
Copy link
Contributor

wclr commented Apr 29, 2017

At least I didn't found if it is possible now.
The case: in package json there is a dependency that required old node version (though it actually work ok), so need to use --ignore-engines flag, it would be nice if ti would be possible to specify for example in pakcage.json:

"yarn": {
  "args": ["ignore-engines"]
}

Or use .yarnrc for specifying this.

@bstro
Copy link

bstro commented May 9, 2017

+1 I work in an organization where the ignore-engines default behavior is super unpractical.

@wclr
Copy link
Contributor Author

wclr commented May 9, 2017

BTW https://github.com/whitecolor/yall supports this you can add to package.json:

"yarn": {
   args: ["--ignore-engines"]
}

@gsklee
Copy link
Contributor

gsklee commented Jun 15, 2017

@bestander close

Forcing developers to pass the --ignore-engines flag explicitly is by design; see this comment.

@wclr
Copy link
Contributor Author

wclr commented Jun 15, 2017

This issue actually has nothing to dot with implicitness/explicitness of particular arguments (--ignore-engines), but simplier management of the process of deps installations. Deafult arguments for particular project/folder, not the whole environment.

@gsklee
Copy link
Contributor

gsklee commented Jun 16, 2017

@whitecolor explicitness by design means that users are required to pass in the --ignore-engines flag explicitly every time whenever relevant commands are invoked. Hiding the flag inside a config file so users don't need to remember to type it every time does not seem to go by the intention of this design.

Regarding the part about adding or modifying package.json or .yarnrc, the current rule mandates that such request should undergo the RFC process.

@tp4k
Copy link

tp4k commented Oct 15, 2018

In .yarnrc --install.ignore-engines true

@ken0x0a
Copy link

ken0x0a commented Mar 21, 2019

for global add
--global.ignore-engines true

@IlyaSemenov
Copy link

FWIW, I'm using alias yarn='yarn --ignore-engines'

@felipecrs
Copy link

For me the following is enough:

$ cat .yarnrc
--ignore-engines true

microsoft/vscode-generator-code#223

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants