巴什完成对Maven逃逸冒号 [英] Bash completion for Maven escapes colon

查看:156
本文介绍了巴什完成对Maven逃逸冒号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我添加bash补全对Maven以下文档:

<一个href=\"http://maven.apache.org/guides/mini/guide-bash-m2-completion.html\">http://maven.apache.org/guides/mini/guide-bash-m2-completion.html

一切运作良好,除了使用冒号的目标。例如,而不是

  MVN日食:日食

完成脱结肠

  MVN蚀\\:月食

任何建议,这可怎么解决吗?我使用Ubuntu 8.10(2.6.27-17-通用)以及


  

$的bash -version结果
  GNU bash的版本3.2.39(1) - 释放(的i486-PC-Linux的GNU)



解决方案

E13常见问题解答。

就在脚本你联系,发出以下命令从完成破字字符列表中移除结肠完整命令后:

  COMP_WORDBREAKS = $ {// COMP_WORDBREAKS:}

I added bash completion for Maven following the docs:

http://maven.apache.org/guides/mini/guide-bash-m2-completion.html

Everything works well except for goals that use a colon. For instance, instead of

mvn eclipse:eclipse

completion escapes the colon

mvn eclipse\:eclipse

Any suggestions how this can be fixed? I'm using Ubuntu 8.10 (2.6.27-17-generic) and

$ bash -version
GNU bash, version 3.2.39(1)-release (i486-pc-linux-gnu)

解决方案

From Bash FAQ E13.

Just after the complete command in the script you linked to, issue this command to remove the colon from the list of completion word break characters:

COMP_WORDBREAKS=${COMP_WORDBREAKS//:}

这篇关于巴什完成对Maven逃逸冒号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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