~ubuntu-branches/ubuntu/vivid/bash-completion/vivid-proposed

« back to all changes in this revision

Viewing changes to completions/lftp

  • Committer: Package Import Robot
  • Author(s): David Paleino
  • Date: 2011-02-06 22:00:58 UTC
  • mfrom: (1.1.4)
  • mto: (5.1.9 sid)
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20110206220058-zfh1gyor3vp1goqc
Tags: 1:1.3-1
* New upstream release
  - Fixed "service" completion, thanks to John Hedges (Closes: #586210)
  - Fixed typo in openssl completion (Closes: #609552)
  - Added ip completion (Closes: #600617)
  - Added _tilde(), fix ~username completion (Closes: #587095)
  - Add *.webm to mplayer file completions (Closes: #588079).
* debian/watch: fix to handle .tar.bz2 files
* Bump Standards-Version to 3.9.1, no changes needed
* Install upstream CHANGES file
* Update copyright years in debian/copyright
* debian/rules: reflect new source layout

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# bash completion for lftp
 
2
 
 
3
have lftp &&
 
4
_lftp()
 
5
{
 
6
    local cur prev
 
7
 
 
8
    COMPREPLY=()
 
9
    _get_comp_words_by_ref cur prev
 
10
 
 
11
    case $prev in
 
12
        -f)
 
13
            _filedir
 
14
            return 0
 
15
            ;;
 
16
        -c|-h|--help|-v|--version|-e|-u|-p)
 
17
            return 0
 
18
            ;;
 
19
    esac
 
20
 
 
21
    if [[ "$cur" == -* ]] ; then
 
22
        COMPREPLY=( $( compgen -W '-f -c --help --version -e -u -p' \
 
23
            -- "$cur" ) )
 
24
        return 0
 
25
    fi
 
26
 
 
27
    COMPREPLY=( $( compgen -W \
 
28
        '$( cut -f 1 -s ~/.lftp/bookmarks 2>/dev/null )' -- "$cur" ) )
 
29
    _known_hosts_real "$cur"
 
30
} &&
 
31
complete -F _lftp lftp
 
32
 
 
33
have lftpget &&
 
34
_lftpget()
 
35
{
 
36
    COMPREPLY=()
 
37
    local cur
 
38
    _get_comp_words_by_ref cur
 
39
 
 
40
    if [[ "$cur" == -* ]] ; then
 
41
        COMPREPLY=( $( compgen -W '-c -d -v' -- "$cur" ) )
 
42
    fi
 
43
} &&
 
44
complete -F _lftpget lftpget
 
45
 
 
46
# Local variables:
 
47
# mode: shell-script
 
48
# sh-basic-offset: 4
 
49
# sh-indent-comment: t
 
50
# indent-tabs-mode: nil
 
51
# End:
 
52
# ex: ts=4 sw=4 et filetype=sh