在节点+ express目录中运行`git add .`时显示Jade中的重复npm警告

时间:2014-09-04 03:46:31

标签: node.js git pug

我启动了一个新的Express目录并运行git add .将其添加到源代码管理中。当我这样做时,我会出现以下错误:

$ express -c stylus
$ sudo npm install -d
$ git init
$ git add .
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/.gitattributes.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/.npmignore.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/.travis.yml.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/LICENSE.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/README.md.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/index.js.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/.npmignore.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/.travis.yml.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/LICENSE.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/README.md.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/index.js.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/node_modules/uglify-js/node_modules/uglify-to-browserify/test/index.js.
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in node_modules/jade/node_modules/constantinople/test/index.js.
The file will have its original line endings in your working directory.

我该如何抑制这些?我应该解决问题还是忽略它?

1 个答案:

答案 0 :(得分:0)

这无法解决问题,但看起来Jade开发人员无法解决此问题 - https://github.com/visionmedia/jade/issues/1128

如果他们愿意,他们可以在本地运行$ git config --global core.autocrlf input以阻止错误产生。