[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 1.3-302-gd8e22da

Ville Skyttä ville.skytta at iki.fi
Sun May 15 12:59:45 UTC 2011


The following commit has been merged in the master branch:
commit 190299ca6a05b26d782196107fc093d586a05da1
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Sun May 15 15:37:09 2011 +0300

    medusa: Use _parse_help, add basic test case.

diff --git a/completions/medusa b/completions/medusa
index d60abcd..f0d538e 100644
--- a/completions/medusa
+++ b/completions/medusa
@@ -24,8 +24,7 @@ _medusa()
     esac
 
     if [[ "$cur" == -* ]]; then
-        COMPREPLY=( $( compgen -W '-h -H -u -U -p -P -C -O -e -M -m -d -n -s \
-            -g -r -R -t -T -L -f -F -b -q -v -w -V -Z' -- "$cur" ) )
+        COMPREPLY=( $( compgen -W '$( _parse_help "$1" )' -- "$cur" ) )
     fi
 } &&
 complete -F _medusa medusa
diff --git a/test/completion/medusa.exp b/test/completion/medusa.exp
new file mode 100644
index 0000000..237cdd5
--- /dev/null
+++ b/test/completion/medusa.exp
@@ -0,0 +1 @@
+assert_source_completions medusa
diff --git a/test/lib/completions/a2ps.exp b/test/lib/completions/medusa.exp
similarity index 79%
copy from test/lib/completions/a2ps.exp
copy to test/lib/completions/medusa.exp
index 77cd07f..6ad2fdc 100644
--- a/test/lib/completions/a2ps.exp
+++ b/test/lib/completions/medusa.exp
@@ -11,7 +11,7 @@ proc teardown {} {
 setup
 
 
-assert_complete_any "a2ps "
+assert_complete_any "medusa -"
 
 
 sync_after_int

-- 
bash-completion



More information about the Bash-completion-commits mailing list