如何在Windows命令行中注释? [英] how to comment in Windows command line?

查看:353
本文介绍了如何在Windows命令行中注释?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Bash中,#用于注释以下内容。我想在Windows命令行中,如何发表评论?



感谢和问候!

方案

您可以使用 rem 来创建备注或更快速的版本 :: 看起来像如果你斜视一下,侧面看: - )



我最喜欢的 :: 变体,因为我是一个 bash - aholic,我仍然试图忘记BASIC的痛苦的日子。不幸的是,有些情况下, :: 填充命令行处理器(例如复杂 if for 语句),所以我通常使用 rem p>

In Bash, # is used to comment the following. I was wondering in Windows command line, how to make a comment?

Thanks and regards!

解决方案

You can either use rem for remark or the more shorthand version ::, which sort of looks like # if you squint a bit and look at it sideways :-)

I originally preferred the :: variant since I'm a bash-aholic and I'm still trying to forget the painful days of BASIC.

Unfortunately, there are situations where :: stuffs up the command line processor (such as within complex if or for statements) so I generally use rem nowadays.

这篇关于如何在Windows命令行中注释?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆