Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
部分项目的 bin 文件的 shebang 行用了 CRLF,因此使用 npminstall 时会报错
env: node\r: No such file or directory
,但是在 npm 下是可以的,因为 npm 内部用了fixBin
来解决这个问题,即在尝试修正 shebang 行的中的\r\n
为\n
npm 那边是 shim-bin 处理也会调用 fixBin 去修复
\r\n
的问题,但貌似 windows 下是没有必要的 https://github.com/npm/bin-links/blob/0d336269938bf47a1532bb8e234e2ac2f8230327/lib/shim-bin.js#L75因此这个 PR 只处理了非 window 的情况
References
Some issues from those packages: