-
Notifications
You must be signed in to change notification settings - Fork 11
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
Does cmdShim() support sh / batch (cmd) / pwsh script as src? #10
Comments
Why doesn't anyone reply? You don't mean to say that the problem of the competitive package manager makes no nevermind to you? Your reply is so late that even a wontfix label turned to be welcome. |
I am sorry. If someone would like to work on this, I will review/merge/publish. I don't have capacity for this at the moment. |
But it probably needs a review from a yarn maintainer because it is needed by yarn. I cannot take the responsibility of approving such changes without approval from official yarn maintainers |
I am the reporter of issue 6913, thank you for finding a deeper problem. My ability is not enough to find such a deep place this time. I have been paying attention to it, and now someone has finally responded. Please do not get angry, I think there may be something in the yarn maintainer that causes them to not pay attention to this issue at this time. |
@zkochan Thank you for your reply. Yarn contributers found a previous version of |
Related:
Yarn for Windows calls
cmdShim()
with the followingsrc
andto
whenyarn global add create-react-app
is executed:src
to
[Yarn global folder]\node_modules\.bin\create-react-app
(for sh)[prefix]\bin\create-react-app
[Yarn global folder]\node_modules\.bin\create-react-app.cmd
[prefix]\bin\create-react-app.cmd
[Yarn global folder]\node_modules\.bin\create-react-app.ps1
[prefix]\bin\create-react-app.ps1
https://github.com/yarnpkg/yarn/blob/1af4c5f50c4c146a833c0c2b20d10be1f5a61803/src/cli/commands/global.js#L168
https://github.com/yarnpkg/yarn/blob/1af4c5f50c4c146a833c0c2b20d10be1f5a61803/src/cli/commands/global.js#L168
As the result, this module creates:
create-react-app.cmd
andcreate-react-app.ps1
, which looks like a batch or PowerShell script but in fact are sh scripts; They can't execute in CMD or PowerShell in spite of their extensions.create-react-app.{ps1,cmd}.{cmd,ps1}
; To make matters worse,create-react-app.ps1.*
can't be executed whenpwsh
(for .NET Core) is not installed.This issue was suppressed in Yarn until this module suppored PowerShell shims because the following code of Yarn, which replace
create-react-app.cmd
(junk sh script) withcreate-react-app.cmd.cmd
:https://github.com/yarnpkg/yarn/blob/1af4c5f50c4c146a833c0c2b20d10be1f5a61803/src/cli/commands/global.js#L169-L171
Anyway, this module must:
src
is a shell (sh, CMD, or PowerShell) script (maybe created by this module).pwsh
is unavailable.The text was updated successfully, but these errors were encountered: