Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
典型的解决方案 ( echo.>filename) 在我的场景中是不可接受的(逃避问题)。还有其他选择吗?
echo.>filename
copy NUL test.txt /Y
/Y 禁止提示确认您要覆盖现有的目标文件。
使用touch命令
touch
$ touch newfile.txt $ ls newfile.txt -rw-r--r-- 1 myuser mygroup 0 Dec 15 15:56 newfile.txt
type nul > "filename here.txt"