nodejs的node_modules在svn下的奇怪问题。
发布于 9 年前 作者 yooluo 4759 次浏览 最后一次编辑是 8 年前 来自 问答

使用express+multer文件上传,在本地使用没有问题,当把模块提交到svn后,再启动express服务就报错误了,看这个错误信息是模块文件夹下出现.svn文件夹引起的错误,由于目前没有办法换源码管理器,有什么办法绕过这个错误吗?

error: uncaughtException: Cannot find module ‘/node/node_modules/multer/node_modules/busboy/lib/types/.svn’ date=Tue Oct 20 2015 21:34:13 GMT+0800 (CST)

看代码是在这一块出的问题,他把整个types文件夹都载入了,正好这个文件夹下有.svn,所以就出错了。 QQ截图20151020222150.png

4 回复

node_modules就别提交进去了啦

svn没有.gitignore这么方便的东东

多年前用svn的时候,可以排除特定文件

狗出结果如下:

To ignore all files with the ending .jpg use:

svn propset svn:ignore “*.jpg” .

If you want to ignore multiple files or folders use:

svn propedit svn:ignore .

This will bring up your text editor so you can enter a list of files or directories to ignore.

你的SVN客户端版本太低了,现在的svn不会在每个目录层次都放一个.svn了

回到顶部