Open tats-u opened 5 years ago
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
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 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 cmd-shim
create *.cmd
(junk sh script shim to .cmd
) and *.cmd.cmd
, and added the makeshift
https://github.com/yarnpkg/yarn/blob/1af4c5f50c4c146a833c0c2b20d10be1f5a61803/src/cli/commands/global.js#L169-L171. I wish the maintainers to understand the need of this change.
I tried to create a PR but it was too difficult for me. Maybe I'll try again, or I wish someone created one on behalf of me.
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-L171Anyway, this module must:
src
is a shell (sh, CMD, or PowerShell) script (maybe created by this module).pwsh
is unavailable.