1

当 gradle 构建完成时,我曾经调用这个命令来弹出一个简单的气球消息。它在 cygwin 的 bash 上运行良好。

notifu /p "Gradle build complete" /m "Now you can take a look at the results" /d 0 > /dev/null

但是,切换到git的bash后,windows风格的命令行选项如/p /m已被解析为cygwin盘符:p:/ m:/. 显然,notifu不能接受他们。

在此处输入图像描述

谁能告诉我为什么它在 cygwin 的 bash 上完美运行,但现在在 git-bash 上却不行?

4

2 回答 2

2

@astrounaut 在git-bash中这样使用:

notifu //p "title" //m "message.."
于 2014-03-03T20:39:18.563 回答
0

我以前使用过(在这里)或看到(在那个答案中)Cygwin msys bash 的转义字符'^'。

^在 前面尝试 a /,以说服 Cygwin 这/p不是驱动路径:

notifu ^/p "Gradle build complete" ^/m "Now you can take a look at the results" ^/d 0 > /dev/null
于 2013-12-24T00:28:54.027 回答