git://git.iain.cx/iain
/
profile.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9e07d4e
)
Added GNU GLOBAL completion.
author
Iain Patterson
<me@iain.cx>
Tue, 8 Jul 2008 12:00:16 +0000
(12:00 +0000)
committer
Iain Patterson
<me@iain.cx>
Tue, 8 Jul 2008 12:00:16 +0000
(12:00 +0000)
git-svn-id: https://svn.cambridge.iain.cx/profile/trunk@113
6be0d1a5
-5cfe-0310-89b6-
964be062b18b
.profile.d/completion.bashrc
patch
|
blob
|
history
diff --git
a/.profile.d/completion.bashrc
b/.profile.d/completion.bashrc
index
fa86e5e
..
ae18697
100644
(file)
--- a/
.profile.d/completion.bashrc
+++ b/
.profile.d/completion.bashrc
@@
-103,6
+103,15
@@
function _rmmod() {
return 0
}
+# Find tags with GNU GLOBAL.
+function _global() {
+ COMPREPLY=()
+ cur=${COMP_WORDS[COMP_CWORD]}
+
+ COMPREPLY=($(global -c "$cur"))
+ return 0
+}
+
complete -F _ssh rollout
complete -F _ssh ssh
complete -F _ssh sshterm
@@
-120,6
+129,7
@@
complete -F _known_hosts kill_known_host
complete -F _known_hosts knh
complete -F _modprobe modprobe
complete -F _rmmod rmmod
+complete -F _global global
unset COMPLETION_DIR_PING
unset COMPLETION_DIR_RDP