如何解决"@echo"无法识别的命令

编程入门 行业动态 更新时间:2024-10-18 06:10:08
本文介绍了如何解决"@echo"无法识别的命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我已经实现了Scott Hanselman的方法来跟上web.config的dev/qa/prod版本: www.hanselman/blog/CommentView.aspx? guid = 93bfa4b3-44cd-4681-b70e-f4a2b0386466

I've implemented Scott Hanselman's method for keeping up with a dev/qa/prod version of web.config: www.hanselman/blog/CommentView.aspx?guid=93bfa4b3-44cd-4681-b70e-f4a2b0386466

出于某种原因,当我编译项目时,我会在输出窗口中收到此错误消息.有什么想法吗?

For some reason when I compile my project I get this error message in my output window. Any ideas?

------ Build started: Project: ABC.Flims.Web, Configuration: Development Any CPU ------ "C:\Projects\ballyhoo-trunk\src\ABC.Flims.Web\scripts/copyifnewer.bat" "C:\Projects\ballyhoo-trunk\src\ABC.Flims.Web\web.config.Development" "C:\Projects\ballyhoo-trunk\src\ABC.Flims.Web\web.config" '@echo' is not recognized as an internal or external command, operable program or batch file.

这是脚本文件:

@echo off echo Comparing two files: %1 with %2 if not exist %1 goto File1NotFound if not exist %2 goto File2NotFound fc %1 %2 if %ERRORLEVEL%==0 GOTO NoCopy echo Files are not the same. Copying %1 over %2 copy %1 %2 /y & goto END :NoCopy echo Files are the same. Did nothing goto END :File1NotFound echo %1 not found. goto END :File2NotFound copy %1 %2 /y goto END :END echo Done.

推荐答案

该文件可能是Unicode编码的,并且具有字节序标记(BOM)在开始时就退出了批处理程序.

The file is probably Unicode encoded and has a Byte Order Mark (BOM) at the start that is throwing off the batch processor.

将其另存为ASCII文件,您应该可以.您可以在notepad中执行此操作-从File菜单中选择Save As...,并确保Encoding下拉菜单设置为ANSI.

Save it as an ASCII file and you should be OK. You can do this in notepad - select Save As... from the File menu and ensure that the Encoding dropdown is set to ANSI.

更多推荐

如何解决"@echo"无法识别的命令

本文发布于:2023-11-28 07:10:30,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1641419.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:如何解决   命令   无法识别   echo   quot

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!