summaryrefslogtreecommitdiff
path: root/completions/_look
blob: 074e924a8aae5f082846265be7f949a438ee7979 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# look(1) completion                                       -*- shell-script -*-

# Use of this file is deprecated on Linux.  Upstream completion is
# available in util-linux >= 2.23, use that instead.

_look()
{
    local cur prev words cword
    _init_completion || return

    if [[ $cword -eq 1 ]]; then
        COMPREPLY=( $(compgen -W '$(look "$cur" 2>/dev/null)' -- "$cur") )
    fi
} &&
complete -F _look -o default look

# ex: filetype=sh