The following commit has been merged in the master branch:
commit 3725168d8a0cdbd9d5ef155e56e75b4cb5951d2b
Author: Ville Skyttä <[email protected]>
Date:   Sun Nov 1 20:52:04 2009 +0200

    Combine dcop and qdbus completions into the latter, they're the same.

diff --git a/CHANGES b/CHANGES
index db2b428..344bca3 100644
--- a/CHANGES
+++ b/CHANGES
@@ -35,6 +35,7 @@ bash-completion (2.x)
     for bash version checks.
   * Fix sed error in qdbus completions containing slashes (Debian: 552631).
   * Add /sbin to $PATH when invoking ifconfig and iwconfig.
+  * Combine dcop and qdbus completions into the latter.
 
   [ Freddy Vulto ]
   * Added _get_pword() helper function, thanks to Sung Pae (Alioth: #312030)
diff --git a/Makefile.am b/Makefile.am
index 94392ad..82035fd 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -30,7 +30,6 @@ bashcomp_DATA = contrib/abook \
                contrib/cpio \
                contrib/cups \
                contrib/cvs \
-               contrib/dcop \
                contrib/dd \
                contrib/dhclient \
                contrib/dict \
diff --git a/contrib/dcop b/contrib/dcop
deleted file mode 100644
index 6f384f7..0000000
--- a/contrib/dcop
+++ /dev/null
@@ -1,26 +0,0 @@
-# bash completion for dcop
-
-have dcop &&
-_dcop()
-{
-    local cur compstr
-
-    COMPREPLY=()
-    cur=`_get_cword`
-    if [ -z $cur ]; then
-        compstr=${COMP_WORDS[*]}
-    else
-        compstr=$( command echo ${COMP_WORDS[*]} | sed "s/ $cur$//" )
-    fi
-    COMPREPLY=( $( compgen -W '$( command $compstr | sed s/\(.*\)// )'  \
-        -- "$cur" ) )
-} &&
-complete -F _dcop dcop
-
-# Local variables:
-# mode: shell-script
-# sh-basic-offset: 4
-# sh-indent-comment: t
-# indent-tabs-mode: nil
-# End:
-# ex: ts=4 sw=4 et filetype=sh
diff --git a/contrib/qdbus b/contrib/qdbus
index 71e3951..bc5252c 100644
--- a/contrib/qdbus
+++ b/contrib/qdbus
@@ -1,6 +1,6 @@
-# Qt qdbus completion
+# Qt qdbus, dcop completion
 
-have qdbus &&
+have qdbus || have dcop &&
 _qdbus()
 {
     local cur
@@ -11,7 +11,7 @@ _qdbus()
     COMPREPLY=( $( compgen -W '$( command ${comp_wor...@]} | sed s/\(.*\)// )' 
\
         -- "$cur" ) )
 } &&
-complete -F _qdbus qdbus
+complete -F _qdbus qdbus dcop
 
 # Local variables:
 # mode: shell-script

-- 
bash-completion

_______________________________________________
Bash-completion-commits mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/bash-completion-commits

Reply via email to