------------------------------------------------------------
revno: 1218
committer: David Paleino <[email protected]>
branch nick: current
timestamp: Fri 2008-12-19 21:58:21 +0100
message:
  Split subversion-related completions to contrib/svn.
added:
  contrib/svn
modified:
  bash_completion
  debian/changelog
=== modified file 'bash_completion'
--- a/bash_completion   2008-12-14 13:05:40 +0000
+++ b/bash_completion   2008-12-19 20:58:21 +0000
@@ -9143,430 +9143,6 @@
 } &&
 complete -F _minicom minicom
 
-# svn completion
-#
-have svn &&
-{
-_svn()
-{
-       local cur prev commands options command
-
-       COMPREPLY=()
-       cur=`_get_cword`
-
-       commands='add blame praise annotate ann cat checkout co cleanup commit \
-               ci copy cp delete del remove rm diff di export help ? h import \
-               info list ls lock log merge mkdir move mv rename ren \
-               propdel pdel pd propedit pedit pe propget pget pg \
-               proplist plist pl propset pset ps resolved revert \
-               status stat st switch sw unlock update up'
-
-       if [[ $COMP_CWORD -eq 1 ]] ; then
-               if [[ "$cur" == -* ]]; then
-                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
-               else
-                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
-               fi
-       else
-
-               prev=${COMP_WORDS[COMP_CWORD-1]}
-               case $prev in
-                       --config-dir)
-                               _filedir -d
-                               return 0;
-                               ;;
-                       -@(F|-file|-targets))
-                               _filedir
-                               return 0;
-                               ;;
-                       --encoding)
-                               COMPREPLY=( $( compgen -W \
-                                       '$( iconv --list | sed -e "s@//@@;" )' \
-                                       -- "$cur" ) )
-                               return 0;
-                               ;;
-                       --@(editor|diff|diff3)-cmd)
-                               COMP_WORDS=(COMP_WORDS[0] $cur)
-                               COMP_CWORD=1
-                               _command
-                               return 0;
-                               ;;
-               esac
-
-               command=${COMP_WORDS[1]}
-
-               if [[ "$cur" == -* ]]; then
-                       # possible options for the command
-                       case $command in
-                               add)
-                                       options='--auto-props --no-auto-props \
-                                               --force --targets --no-ignore \
-                                               --non-recursive -N -q --quiet'
-                                       ;;
-                               @(blame|annotate|ann|praise))
-                                       options='-r --revisions --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive -v \
-                                               --verbose --incremental --xml'
-                                       ;;
-                               cat)
-                                       options='-r --revision --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(checkout|co))
-                                       options='-r --revision -q --quiet -N \
-                                               --non-recursive --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive \
-                                               --ignore-externals'
-                                       ;;
-                               cleanup)
-                                       options='--diff3-cmd'
-                                       ;;
-                               @(commit|ci))
-                                       options='-m --message -F --file \
-                                               --encoding --force-log -q \
-                                               --quiet --non-recursive -N \
-                                               --targets --editor-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive --no-unlock'
-                                       ;;
-                               @(copy|cp))
-                                       options='-m --message -F --file \
-                                               --encoding --force-log -r \
-                                               --revision -q --quiet \
-                                               --editor-cmd -username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(delete|del|remove|rm))
-                                       options='--force -m --message -F \
-                                               --file --encoding --force-log \
-                                               -q --quiet --targets \
-                                               --editor-cmd -username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(diff|di))
-                                       options='-r --revision -x --extensions \
-                                               --diff-cmd --no-diff-deleted \
-                                               -N --non-recursive --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive --force \
-                                               --old --new --notice-ancestry'
-                                       ;;
-                               export)
-                                       options='-r --revision -q --quiet \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive -N \
-                                               --non-recursive --force \
-                                               --native-eol --ignore-externals'
-                                       ;;
-                               import)
-                                       options='--auto-props --no-auto-props \
-                                               -m --message -F --file \
-                                               --encoding --force-log -q \
-                                               --quiet --non-recursive \
-                                               --no-ignore --editor-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               info)
-                                       options='--username --password \
-                                               --no-auth-cache \
-                                               --non-interactive -r \
-                                               --revision --xml --targets \
-                                               -R --recursive --incremental'
-                                       ;;
-                               @(list|ls))
-                                       options='-r --revision -v --verbose -R \
-                                               --recursive --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive \
-                                               --incremental --xml'
-                                       ;;
-                               lock)
-                                       options='-m --message -F --file \
-                                               --encoding --force-log \
-                                               --targets --force --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               log)
-                                       options='-r --revision -v --verbose \
-                                               --targets --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive \
-                                               --stop-on-copy --incremental \
-                                               --xml -q --quiet --limit'
-                                       ;;
-                               merge)
-                                       options='-r --revision -N \
-                                               --non-recursive -q --quiet \
-                                               --force --dry-run --diff3-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive \
-                                               --ignore-ancestry'
-                                       ;;
-                               mkdir)
-                                       options='-m --message -F --file \
-                                               --encoding --force-log -q \
-                                               --quiet --editor-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(move|mv|rename|ren))
-                                       options='-m --message -F --file \
-                                               --encoding --force-log -r \
-                                               --revision -q --quiet \
-                                               --force --editor-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(propdel|pdel|pd))
-                                       options='-q --quiet -R --recursive -r \
-                                               --revision --revprop \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(propedit|pedit|pe))
-                                       options='-r --revision --revprop \
-                                               --encoding --editor-cmd \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive --force'
-                                       ;;
-                               @(propget|pget|pg))
-                                       options='-R --recursive -r --revision \
-                                               --revprop --strict --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(proplist|plist|pl))
-                                       options='-v --verbose -R --recursive \
-                                               -r --revision --revprop -q \
-                                               --quiet --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(propset|pset|ps))
-                                       options='-F --file -q --quiet \
-                                               --targets -R --recursive \
-                                               --revprop --encoding \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive -r \
-                                               --revision --force'
-                                       ;;
-                               resolved)
-                                       options='--targets -R --recursive -q \
-                                               --quiet'
-                                       ;;
-                               revert)
-                                       options='--targets -R --recursive -q \
-                                               --quiet'
-                                       ;;
-                               @(status|stat|st))
-                                       options='-u --show-updates -v \
-                                               --verbose -N --non-recursive \
-                                               -q --quiet --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive --no-ignore \
-                                               --ignore-externals \
-                                               --incremental --xml'
-                                       ;;
-                               @(switch|sw))
-                                       options='--relocate -r --revision -N \
-                                               --non-recursive -q --quiet \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive --diff3-cmd'
-                                       ;;
-                               unlock)
-                                       options='--targets --force --username \
-                                               --password --no-auth-cache \
-                                               --non-interactive'
-                                       ;;
-                               @(update|up))
-                                       options='-r --revision -N \
-                                               --non-recursive -q --quiet \
-                                               --username --password \
-                                               --no-auth-cache \
-                                               --non-interactive \
-                                               --diff3-cmd --ignore-externals'
-                                       ;;
-                       esac
-                       options="$options --help -h --config-dir"
-
-                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
-               else
-                       if [[ "$command" == @(help|h|\?) ]]; then
-                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
-                       else
-                               _filedir
-                       fi
-               fi
-       fi
-
-       return 0
-}
-complete -F _svn $default svn
-
-_svnadmin()
-{
-       local cur prev commands options mode
-
-       COMPREPLY=()
-       cur=`_get_cword`
-
-       commands='create deltify dump help ? hotcopy list-dblogs \
-               list-unused-dblogs load lslocks lstxns recover rmlocks \
-               rmtxns setlog verify'
-
-       if [[ $COMP_CWORD -eq 1 ]] ; then
-               if [[ "$cur" == -* ]]; then
-                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
-               else
-                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
-               fi
-       else
-               prev=${COMP_WORDS[COMP_CWORD-1]}
-               case $prev in
-                       --config-dir)
-                               _filedir -d
-                               return 0;
-                               ;;
-                       --fs-type)
-                               COMPREPLY=( $( compgen -W 'fsfs bdb' -- $cur ) )
-                               return 0;
-                               ;;
-               esac
-
-               command=${COMP_WORDS[1]}
-
-               if [[ "$cur" == -* ]]; then
-                       # possible options for the command
-                       case $command in
-                               create)
-                                       options='--bdb-txn-nosync \
-                                               --bdb-log-keep --config-dir \
-                                               --fs-type'
-                                       ;;
-                               deltify)
-                                       options='-r --revision -q --quiet'
-                                       ;;
-                               dump)
-                                       options='-r --revision --incremental \
-                                               -q --quiet --deltas'
-                                       ;;
-                               hotcopy)
-                                       options='--clean-logs'
-                                       ;;
-                               load)
-                                       options='--ignore-uuid --force-uuid \
-                                               --parent-dir -q --quiet \
-                                               --use-pre-commit-hook \
-                                               --use-post-commit-hook'
-                                       ;;
-                               rmtxns)
-                                       options='-q --quiet'
-                                       ;;
-                               setlog)
-                                       options='-r --revision --bypass-hooks'
-                                       ;;
-                       esac
-
-                       options="$options --help -h"
-                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
-               else
-                       if [[ "$command" == @(help|h|\?) ]]; then
-                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
-                       else
-                               _filedir
-                       fi
-               fi
-       fi
-
-       return 0
-}
-complete -F _svnadmin $default svnadmin
-
-_svnlook()
-{
-       local cur prev commands options mode
-
-       COMPREPLY=()
-       cur=`_get_cword`
-
-       commands='author cat changed date diff dirs-changed help ? h history \
-               info lock log propget pget pg proplist plist pl tree uuid \
-               youngest'
-
-       if [[ $COMP_CWORD -eq 1 ]] ; then
-               if [[ "$cur" == -* ]]; then
-                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
-               else
-                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
-               fi
-       else
-               command=${COMP_WORDS[1]}
-
-               if [[ "$cur" == -* ]]; then
-                       # possible options for the command
-                       case $command in
-                               @(author|cat|date|dirs-changed|info|log))
-                                       options='-r --revision -t \
-                                               --transaction'
-                                       ;;
-                               changed)
-                                       options='-r --revision -t \
-                                               --transaction --copy-info'
-                                       ;;
-                               diff)
-                                       options='-r --revision -t \
-                                               --transaction \
-                                               --no-diff-deleted \
-                                               --no-diff-added \
-                                               --diff-copy-from'
-                                       ;;
-                               history)
-                                       options='-r --revision --show-ids'
-                                       ;;
-                               prop@(get|list))
-                                       options='-r --revision -t \
-                                               --transaction --revprop'
-                                       ;;
-                               tree)
-                                       options='-r --revision -t \
-                                               --transaction --show-ids \
-                                               --full-paths'
-                                       ;;
-                       esac
-
-                       options="$options --help -h"
-                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
-               else
-                       if [[ "$command" == @(help|h|\?) ]]; then
-                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
-                       else
-                               _filedir
-                       fi
-               fi
-       fi
-
-       return 0
-}
-complete -F _svnlook $default svnlook
-}
-
 have rrdtool &&
 _rrdtool ()
 {

=== added file 'contrib/svn'
--- a/contrib/svn       1970-01-01 00:00:00 +0000
+++ b/contrib/svn       2008-12-19 20:58:21 +0000
@@ -0,0 +1,423 @@
+# svn completion
+#
+have svn &&
+{
+_svn()
+{
+       local cur prev commands options command
+
+       COMPREPLY=()
+       cur=`_get_cword`
+
+       commands='add blame praise annotate ann cat checkout co cleanup commit \
+               ci copy cp delete del remove rm diff di export help ? h import \
+               info list ls lock log merge mkdir move mv rename ren \
+               propdel pdel pd propedit pedit pe propget pget pg \
+               proplist plist pl propset pset ps resolved revert \
+               status stat st switch sw unlock update up'
+
+       if [[ $COMP_CWORD -eq 1 ]] ; then
+               if [[ "$cur" == -* ]]; then
+                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
+               else
+                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
+               fi
+       else
+
+               prev=${COMP_WORDS[COMP_CWORD-1]}
+               case $prev in
+                       --config-dir)
+                               _filedir -d
+                               return 0;
+                               ;;
+                       -@(F|-file|-targets))
+                               _filedir
+                               return 0;
+                               ;;
+                       --encoding)
+                               COMPREPLY=( $( compgen -W \
+                                       '$( iconv --list | sed -e "s@//@@;" )' \
+                                       -- "$cur" ) )
+                               return 0;
+                               ;;
+                       --@(editor|diff|diff3)-cmd)
+                               COMP_WORDS=(COMP_WORDS[0] $cur)
+                               COMP_CWORD=1
+                               _command
+                               return 0;
+                               ;;
+               esac
+
+               command=${COMP_WORDS[1]}
+
+               if [[ "$cur" == -* ]]; then
+                       # possible options for the command
+                       case $command in
+                               add)
+                                       options='--auto-props --no-auto-props \
+                                               --force --targets --no-ignore \
+                                               --non-recursive -N -q --quiet'
+                                       ;;
+                               @(blame|annotate|ann|praise))
+                                       options='-r --revisions --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive -v \
+                                               --verbose --incremental --xml'
+                                       ;;
+                               cat)
+                                       options='-r --revision --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(checkout|co))
+                                       options='-r --revision -q --quiet -N \
+                                               --non-recursive --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive \
+                                               --ignore-externals'
+                                       ;;
+                               cleanup)
+                                       options='--diff3-cmd'
+                                       ;;
+                               @(commit|ci))
+                                       options='-m --message -F --file \
+                                               --encoding --force-log -q \
+                                               --quiet --non-recursive -N \
+                                               --targets --editor-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive --no-unlock'
+                                       ;;
+                               @(copy|cp))
+                                       options='-m --message -F --file \
+                                               --encoding --force-log -r \
+                                               --revision -q --quiet \
+                                               --editor-cmd -username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(delete|del|remove|rm))
+                                       options='--force -m --message -F \
+                                               --file --encoding --force-log \
+                                               -q --quiet --targets \
+                                               --editor-cmd -username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(diff|di))
+                                       options='-r --revision -x --extensions \
+                                               --diff-cmd --no-diff-deleted \
+                                               -N --non-recursive --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive --force \
+                                               --old --new --notice-ancestry'
+                                       ;;
+                               export)
+                                       options='-r --revision -q --quiet \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive -N \
+                                               --non-recursive --force \
+                                               --native-eol --ignore-externals'
+                                       ;;
+                               import)
+                                       options='--auto-props --no-auto-props \
+                                               -m --message -F --file \
+                                               --encoding --force-log -q \
+                                               --quiet --non-recursive \
+                                               --no-ignore --editor-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               info)
+                                       options='--username --password \
+                                               --no-auth-cache \
+                                               --non-interactive -r \
+                                               --revision --xml --targets \
+                                               -R --recursive --incremental'
+                                       ;;
+                               @(list|ls))
+                                       options='-r --revision -v --verbose -R \
+                                               --recursive --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive \
+                                               --incremental --xml'
+                                       ;;
+                               lock)
+                                       options='-m --message -F --file \
+                                               --encoding --force-log \
+                                               --targets --force --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               log)
+                                       options='-r --revision -v --verbose \
+                                               --targets --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive \
+                                               --stop-on-copy --incremental \
+                                               --xml -q --quiet --limit'
+                                       ;;
+                               merge)
+                                       options='-r --revision -N \
+                                               --non-recursive -q --quiet \
+                                               --force --dry-run --diff3-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive \
+                                               --ignore-ancestry'
+                                       ;;
+                               mkdir)
+                                       options='-m --message -F --file \
+                                               --encoding --force-log -q \
+                                               --quiet --editor-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(move|mv|rename|ren))
+                                       options='-m --message -F --file \
+                                               --encoding --force-log -r \
+                                               --revision -q --quiet \
+                                               --force --editor-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(propdel|pdel|pd))
+                                       options='-q --quiet -R --recursive -r \
+                                               --revision --revprop \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(propedit|pedit|pe))
+                                       options='-r --revision --revprop \
+                                               --encoding --editor-cmd \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive --force'
+                                       ;;
+                               @(propget|pget|pg))
+                                       options='-R --recursive -r --revision \
+                                               --revprop --strict --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(proplist|plist|pl))
+                                       options='-v --verbose -R --recursive \
+                                               -r --revision --revprop -q \
+                                               --quiet --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(propset|pset|ps))
+                                       options='-F --file -q --quiet \
+                                               --targets -R --recursive \
+                                               --revprop --encoding \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive -r \
+                                               --revision --force'
+                                       ;;
+                               resolved)
+                                       options='--targets -R --recursive -q \
+                                               --quiet'
+                                       ;;
+                               revert)
+                                       options='--targets -R --recursive -q \
+                                               --quiet'
+                                       ;;
+                               @(status|stat|st))
+                                       options='-u --show-updates -v \
+                                               --verbose -N --non-recursive \
+                                               -q --quiet --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive --no-ignore \
+                                               --ignore-externals \
+                                               --incremental --xml'
+                                       ;;
+                               @(switch|sw))
+                                       options='--relocate -r --revision -N \
+                                               --non-recursive -q --quiet \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive --diff3-cmd'
+                                       ;;
+                               unlock)
+                                       options='--targets --force --username \
+                                               --password --no-auth-cache \
+                                               --non-interactive'
+                                       ;;
+                               @(update|up))
+                                       options='-r --revision -N \
+                                               --non-recursive -q --quiet \
+                                               --username --password \
+                                               --no-auth-cache \
+                                               --non-interactive \
+                                               --diff3-cmd --ignore-externals'
+                                       ;;
+                       esac
+                       options="$options --help -h --config-dir"
+
+                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
+               else
+                       if [[ "$command" == @(help|h|\?) ]]; then
+                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
+                       else
+                               _filedir
+                       fi
+               fi
+       fi
+
+       return 0
+}
+complete -F _svn $default svn
+
+_svnadmin()
+{
+       local cur prev commands options mode
+
+       COMPREPLY=()
+       cur=`_get_cword`
+
+       commands='create deltify dump help ? hotcopy list-dblogs \
+               list-unused-dblogs load lslocks lstxns recover rmlocks \
+               rmtxns setlog verify'
+
+       if [[ $COMP_CWORD -eq 1 ]] ; then
+               if [[ "$cur" == -* ]]; then
+                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
+               else
+                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
+               fi
+       else
+               prev=${COMP_WORDS[COMP_CWORD-1]}
+               case $prev in
+                       --config-dir)
+                               _filedir -d
+                               return 0;
+                               ;;
+                       --fs-type)
+                               COMPREPLY=( $( compgen -W 'fsfs bdb' -- $cur ) )
+                               return 0;
+                               ;;
+               esac
+
+               command=${COMP_WORDS[1]}
+
+               if [[ "$cur" == -* ]]; then
+                       # possible options for the command
+                       case $command in
+                               create)
+                                       options='--bdb-txn-nosync \
+                                               --bdb-log-keep --config-dir \
+                                               --fs-type'
+                                       ;;
+                               deltify)
+                                       options='-r --revision -q --quiet'
+                                       ;;
+                               dump)
+                                       options='-r --revision --incremental \
+                                               -q --quiet --deltas'
+                                       ;;
+                               hotcopy)
+                                       options='--clean-logs'
+                                       ;;
+                               load)
+                                       options='--ignore-uuid --force-uuid \
+                                               --parent-dir -q --quiet \
+                                               --use-pre-commit-hook \
+                                               --use-post-commit-hook'
+                                       ;;
+                               rmtxns)
+                                       options='-q --quiet'
+                                       ;;
+                               setlog)
+                                       options='-r --revision --bypass-hooks'
+                                       ;;
+                       esac
+
+                       options="$options --help -h"
+                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
+               else
+                       if [[ "$command" == @(help|h|\?) ]]; then
+                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
+                       else
+                               _filedir
+                       fi
+               fi
+       fi
+
+       return 0
+}
+complete -F _svnadmin $default svnadmin
+
+_svnlook()
+{
+       local cur prev commands options mode
+
+       COMPREPLY=()
+       cur=`_get_cword`
+
+       commands='author cat changed date diff dirs-changed help ? h history \
+               info lock log propget pget pg proplist plist pl tree uuid \
+               youngest'
+
+       if [[ $COMP_CWORD -eq 1 ]] ; then
+               if [[ "$cur" == -* ]]; then
+                       COMPREPLY=( $( compgen -W '--version' -- $cur ) )
+               else
+                       COMPREPLY=( $( compgen -W "$commands" -- $cur ) )
+               fi
+       else
+               command=${COMP_WORDS[1]}
+
+               if [[ "$cur" == -* ]]; then
+                       # possible options for the command
+                       case $command in
+                               @(author|cat|date|dirs-changed|info|log))
+                                       options='-r --revision -t \
+                                               --transaction'
+                                       ;;
+                               changed)
+                                       options='-r --revision -t \
+                                               --transaction --copy-info'
+                                       ;;
+                               diff)
+                                       options='-r --revision -t \
+                                               --transaction \
+                                               --no-diff-deleted \
+                                               --no-diff-added \
+                                               --diff-copy-from'
+                                       ;;
+                               history)
+                                       options='-r --revision --show-ids'
+                                       ;;
+                               prop@(get|list))
+                                       options='-r --revision -t \
+                                               --transaction --revprop'
+                                       ;;
+                               tree)
+                                       options='-r --revision -t \
+                                               --transaction --show-ids \
+                                               --full-paths'
+                                       ;;
+                       esac
+
+                       options="$options --help -h"
+                       COMPREPLY=( $( compgen -W "$options" -- $cur ) )
+               else
+                       if [[ "$command" == @(help|h|\?) ]]; then
+                               COMPREPLY=( $( compgen -W "$commands" -- $cur ) 
)
+                       else
+                               _filedir
+                       fi
+               fi
+       fi
+
+       return 0
+}
+complete -F _svnlook $default svnlook
+}
\ No newline at end of file

=== modified file 'debian/changelog'
--- a/debian/changelog  2008-12-14 13:05:40 +0000
+++ b/debian/changelog  2008-12-19 20:58:21 +0000
@@ -46,6 +46,7 @@
   * TODO updated: the Alioth team is now upstream.
   * Added qdbus completion, thanks to Terence Simpson (LP: #257903)
   * Added monodevelop and mdtool completions.
+  * Split subversion-related completions to contrib/svn.
   * Merge from Gentoo:
     - fix 'find' completion so that it properly completes on -?(i)whilename.
       Patch by Ciaran McCreesh.
@@ -59,7 +60,7 @@
   * debian/install:
     - correctly install contrib/* under /etc/bash_completion.d/
 
- -- David Paleino <[email protected]>  Sun, 14 Dec 2008 14:05:12 +0100
+ -- David Paleino <[email protected]>  Fri, 19 Dec 2008 21:57:51 +0100
 
 bash-completion (20080705) unstable; urgency=low
 

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

Reply via email to