ruby-on-rails - 环境 : node\r: No such file or directory with browserify-rails

标签 ruby-on-rails ruby git npm browserify

一切顺利。想使用 ios 模拟器,但 xcode 想更新。为什么不?做过某事。一切都好。完成 git 添加、提交和 merge 。 merge 后:

Error while running /Users/sylar/Sites/rails/demo/node_modules/.bin/browserifyinc --transform reactify --extension=".jsx" --list --cachefile=/Users/sylar/Sites/rails/demo/tmp/cache/browserify-rails/browserifyinc-cache.json -o "/Users/sylar/Sites/rails/demo/tmp/cache/browserify-rails/output20160319-1425-142q6j7" -:

env: node\r: No such file or directory

我在 Mac 10.11.13

运行这些命令但没有任何改变:rake tmp:cache:clearrm -rf ./tmp

听说这个问题是由 git commit 引起的,但不确定它是如何工作的。我所做的只是更新了 xcode,然后是 git merge。检查最后一个工作分支但同样的问题。

最佳答案

您有一个以 shebang 结尾的 dos 行脚本的行(\r\n 而不是 \n,并且也可能已在其他行中复制);执行 fromdos在脚本文件上你可以使用tr like

tr -d '\015' < scriptfile > scriptfile.new

然后

mv scriptfile.new scriptfile

关于ruby-on-rails - 环境 : node\r: No such file or directory with browserify-rails,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36106525/

相关文章:

git - 如何仅在预提交 git 钩子(Hook)中删除更改行上的尾随空格?

ruby-on-rails - 在 Rails 应用程序中为管理界面定义单独的 View 和 Assets

ruby-on-rails - 在本地服务器上使用 RestKit

ruby-on-rails - Resque工作线程立即失败: undefined method `write' for nil:NilClass

Ruby 方法如 `self` 引用实例

git - Wiki.js不适用于预先存在的存储库

生产中的 CSS 不同

ruby - 关于 pgrep 返回自身的确认

Ruby:ARGV 打破重音字符

linux - 无法从其中一台 Linux 服务器连接到 GIT 存储库