r1032 - in /trunk/packages/vim-addon-manager: debian/changelog debian/vim-addon-manager.install etc/ etc/bash_completion.d/ etc/bash_completion.d/vim-addon-manager

zack at users.alioth.debian.org zack at users.alioth.debian.org
Sat Sep 22 18:03:47 UTC 2007


Author: zack
Date: Sat Sep 22 18:03:46 2007
New Revision: 1032

URL: http://svn.debian.org/wsvn/pkg-vim/?sc=1&rev=1032
Log:
adding bash completion (preliminary version)

Added:
    trunk/packages/vim-addon-manager/etc/
    trunk/packages/vim-addon-manager/etc/bash_completion.d/
    trunk/packages/vim-addon-manager/etc/bash_completion.d/vim-addon-manager
Modified:
    trunk/packages/vim-addon-manager/debian/changelog
    trunk/packages/vim-addon-manager/debian/vim-addon-manager.install

Modified: trunk/packages/vim-addon-manager/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim-addon-manager/debian/changelog?rev=1032&op=diff
==============================================================================
--- trunk/packages/vim-addon-manager/debian/changelog (original)
+++ trunk/packages/vim-addon-manager/debian/changelog Sat Sep 22 18:03:46 2007
@@ -2,11 +2,18 @@
 
   * debian/control
     - better long description
+  * debian/copyright
+    - change license to GPL 3 or above, fixed source file headers accordingly
   * vim-addons
     - add 'show' command which show in a 822-like format a more detailed
-      report of each addons and its status (Closes: #438154)
+      report of each addons and its status (closes: #438154)
+    - add '-q' option which make the output of the 'status' command more
+      parsable and only show addons wrt the current execution mode
+      (system-wide or not)
+  * add bash completion script contributed by Antonio Terceiro
+    (closes: #440843); fix debian/*.install accordingly
 
- -- Stefano Zacchiroli <zack at debian.org>  Sun, 19 Aug 2007 10:56:49 +0200
+ -- Stefano Zacchiroli <zack at debian.org>  Sat, 22 Sep 2007 20:00:37 +0200
 
 vim-addon-manager (0.2) unstable; urgency=low
 

Modified: trunk/packages/vim-addon-manager/debian/vim-addon-manager.install
URL: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim-addon-manager/debian/vim-addon-manager.install?rev=1032&op=diff
==============================================================================
--- trunk/packages/vim-addon-manager/debian/vim-addon-manager.install (original)
+++ trunk/packages/vim-addon-manager/debian/vim-addon-manager.install Sat Sep 22 18:03:46 2007
@@ -1,2 +1,3 @@
-src/vim-addons	    /usr/bin/
-src/vim		    /usr/lib/ruby/1.8/
+src/vim-addons		/usr/bin/
+src/vim			/usr/lib/ruby/1.8/
+etc/bash_completion.d	/etc/

Added: trunk/packages/vim-addon-manager/etc/bash_completion.d/vim-addon-manager
URL: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim-addon-manager/etc/bash_completion.d/vim-addon-manager?rev=1032&op=file
==============================================================================
--- trunk/packages/vim-addon-manager/etc/bash_completion.d/vim-addon-manager (added)
+++ trunk/packages/vim-addon-manager/etc/bash_completion.d/vim-addon-manager Sat Sep 22 18:03:46 2007
@@ -1,0 +1,51 @@
+# vim-addons completion script for vim-addons
+# 
+# Copyright (c) 2007, Antonio Terceiro <terceiro at softwarelivre.org>
+# 
+# This program is free software, you can redistribute it and/or modify it under
+# the terms of the GNU General Public License version 2 as published by the
+# Free Software Foundation; either version 2 of the License, or (at your
+# option) any later version.
+
+_complete_vim_addons() {
+
+  COMPREPLY=()
+  cur=${COMP_WORDS[COMP_CWORD]}
+  prev=${COMP_WORDS[COMP_CWORD-1]}
+
+  commands="list status install remove disable amend files show"
+  options="-h --help -r --registry-dir -s --source-dir -t --target-dir -v --verbose -y --system-dir -w --system-wide"
+
+  # complete option names
+  if [[ "$cur" == -* ]]; then
+    COMPREPLY=( $( compgen -W "$options" -- $cur) )
+    return 0
+  fi
+
+  case "$prev" in
+
+    # complete commands
+    vim-addons)
+      COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
+      return 0
+      ;;
+
+    # complete directory names
+    -r|--registry-dir|-s|--source-dir|-t|--target-dir|-y|--system-dir)
+      COMPREPLY=( $( compgen -o dirnames -- $cur ) )
+      return 0
+      ;;
+
+    # complete addon names
+    *)
+      COMPREPLY=($(grep -h "^addon: $cur" /usr/share/vim/registry/*.yaml | sed -e 's/^addon:\s*//'))
+
+      return 0
+      ;;
+  esac
+
+
+}
+
+complete -F _complete_vim_addons -o default vim-addons
+




More information about the pkg-vim-maintainers mailing list