Newline problems with Subversion

当一个文件在*nix和Windows下多次操作后,可能混合了2种断行格式,在导入包含此种文件的项目时,常出现以下错误:File '/home/pal/workspace/proobox/build.xml' has inconsistent newlines,解决的办法就是去掉相关文件的svn:eol-style : native属性,也可以直接修改svn的客户端配置文件,修改全局属性,以便提交新文件时也能不受此问题影响。(即修改[auto-props]内相应内容,去掉svn:eol-style : native的设置)

单个文件属性修改详见以下办法:

Newline problems with Subversion

On my current project, developers work from Linux and Windows together, and we ran into the following problem when trying to commit from Eclipse:

Commit failed (details follow): svn: File '/home/pal/workspace/proobox/build.xml' has inconsistent newlines

Well, someone else already had this problem, and the solution was to remove the keyword svn:eol-style from the file in Subversion.

In Eclipse, select Team/Show Keywords and remove the keyword, in command prompt:

$ svn proplist -v build.xml
Properties on 'build.xml':
svn:keywords : author date id revision
svn:eol-style : native
	
$ svn propdel svn:eol-style build.xml
property 'svn:eol-style' deleted from 'build.xml'.

Your now ready to commit, and problem is solved! :)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值