~ubuntu-branches/ubuntu/trusty/bash-completion/trusty-updates

« back to all changes in this revision

Viewing changes to completions/svk

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher
  • Date: 2012-07-23 16:07:59 UTC
  • mfrom: (5.1.12 sid)
  • Revision ID: package-import@ubuntu.com-20120723160759-lt9vn33dl3nak9l0
Tags: 1:2.0-1ubuntu1
* debian/maintscript, debian/postinst:
  - clean etc conffiles on upgrade since completion files are in /usr
    with the new version
* Resync with Debian, remaining diff
  * debian/patches/disable-avahi-browse.diff: Disable avahi-browse since
    it scales poorly in the current form: refresh patch
  * patches/101_bash_completion.oga_ogv.patch: Increase support for other
    OGG formats including .oga, .ogx, etc. (LP: #311525)
  * patches/103_colormake.patch: Add support for colormake to the make
    completion rules. (LP: #743208)
* Dropped changes:
  * Add conffile upgrade handling for a run of conffiles that were dropped
    since lucid: lucid upgrades are only supported to precise.
* Those fixes are in the new version
  * debian/patches/apt-get-changelog.patch:
  * Drop whitelists if they fail to produce any results:
  * patches/apt-get-download.patch: Add download as an apt-get
    sub-command (LP: #720541)
  * patches/102_manpager.patch: Override MANPAGER when generating perldoc
    completions.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# svk(1) completion
 
1
# svk(1) completion                                        -*- shell-script -*-
2
2
 
3
 
have svk &&
4
3
_svk()
5
4
{
6
 
    local cur prev commands options command
 
5
    local cur prev words cword
 
6
    _init_completion || return
7
7
 
8
 
    COMPREPLY=()
9
 
    _get_comp_words_by_ref cur prev
 
8
    local commands options command
10
9
 
11
10
    commands='add admin annotate ann blame praise cat checkout co cleanup \
12
11
        cmerge cm commit ci copy cp delete del remove rm depotmap \
16
15
        pset pull push resolved revert smerge sm status st stat switch \
17
16
        sw sync sy update up verify'
18
17
 
19
 
    if [[ $COMP_CWORD -eq 1 ]] ; then
 
18
    if [[ $cword -eq 1 ]] ; then
20
19
        if [[ "$cur" == -* ]]; then
21
20
            COMPREPLY=( $( compgen -W '--version' -- "$cur" ) )
22
21
        else
26
25
        case $prev in
27
26
            -F|--file|--targets)
28
27
                _filedir
29
 
                return 0;
 
28
                return 0
30
29
                ;;
31
30
            --encoding)
32
31
                COMPREPLY=( $( compgen -W \
33
32
                    '$( iconv --list | sed -e "s@//@@;" )' -- "$cur" ) )
34
 
                return 0;
 
33
                return 0
35
34
                ;;
36
35
        esac
37
36
 
38
 
        command=${COMP_WORDS[1]}
 
37
        command=${words[1]}
39
38
 
40
39
        if [[ "$cur" == -* ]]; then
41
40
            # possible options for the command
173
172
                        -s --sync -m --merge -q --quiet'
174
173
                    ;;
175
174
            esac
176
 
            options="$options --help -h"
 
175
            options+=" --help -h"
177
176
 
178
177
            COMPREPLY=( $( compgen -W "$options" -- "$cur" ) )
179
178
        else
216
215
} &&
217
216
complete -F _svk svk
218
217
 
219
 
# Local variables:
220
 
# mode: shell-script
221
 
# sh-basic-offset: 4
222
 
# sh-indent-comment: t
223
 
# indent-tabs-mode: nil
224
 
# End:
225
218
# ex: ts=4 sw=4 et filetype=sh