问题描述
我们怎么能...
请参阅下面的详细信息。
文件
命令行patch
失败
补丁文件中的DOS换行符转换为Unix换行符并进行修补 失败:
[0] mypc<u0>:~/src/test/ant_patch_crlf>patch -i test.patch
(Stripping trailing CRs from patch; use --binary to disable.)
patching file test.txt
Hunk #1 Failed at 1 (different line endings).
1 out of 1 hunk Failed -- saving rejects to file test.txt.rej
命令行patch --binary
正常工作
如上所述。
use --binary to disable
添加选项--binary
有帮助:
[0] mypc<u0>:~/src/test/ant_patch_crlf>patch --binary -i test.patch
patching file test.txt
蚂蚁任务patch
失败
蚂蚁任务patch
失败,错误与命令行相同,但没有
选项--binary
:
[0] mypc<u0>:~/src/test/ant_patch_crlf>ant
Buildfile: /home/u0/src/test/ant_patch_crlf/build.xml
patch:
[patch] (Stripping trailing CRs from patch; use --binary to disable.)
[patch] patching file test.txt
[patch] Hunk #1 Failed at 1 (different line endings).
[patch] 1 out of 1 hunk Failed -- saving rejects to file test.txt.rej
[patch] 'patch' Failed with exit code 1
BUILD SUCCESSFUL
Total time: 0 seconds
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)