Mingw64,路径的反斜杠被转义。什么设置它不转义呢?

2016-08-03 17:42:45 +08:00
 lzjamao
简单来说:
有文件 aa\bb\FILE.txt
打开 Mingw64 ,执行命令
$ rm aa\bb\FILE.txt
rm: cannot remove 'aabbFILE.txt': No such file or directory

这个问题
在 Windoww Mingw64 执行 svn status 时碰到。
svn status 所输出的文件路径都是以'\'分隔路径。
至于 svn delete 鼠标中键选中文件时,删除失败。

我想知道
1. 不使用双引号包住路径
2. 不将反斜杠改为斜杠
如何取消转义。

感激不尽
3334 次点击
所在节点    Linux
4 条回复
qnnnnez
2016-08-03 17:57:17 +08:00
看起来你在用 bash
win32 可以兼容 /的,只是 cmd 不兼容 /
lslqtz
2016-08-04 05:28:04 +08:00
lslqtz@PC-Win10 MINGW64 ~
$ aa\bb\cc.txt
bash: aabbcc.txt: command not found

lslqtz@PC-Win10 MINGW64 ~
$
确定是这样了。。
lslqtz
2016-08-04 05:28:56 +08:00
lslqtz@PC-Win10 MINGW64 ~
$ "aa\bb"
bash: aa\bb: No such file or directory

lslqtz@PC-Win10 MINGW64 ~
$
lslqtz
2016-08-04 05:30:02 +08:00
lslqtz@PC-Win10 MINGW64 ~
$ aa\\bb
bash: aa\bb: No such file or directory

lslqtz@PC-Win10 MINGW64 ~
$

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/296894

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX