HEX
Server: nginx/1.22.0
System: Linux iZuf6jdxbygmf6cco977lcZ 5.10.84-10.4.al8.x86_64 #1 SMP Tue Apr 12 12:31:07 CST 2022 x86_64
User: root (0)
PHP: 7.4.29
Disabled: passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen
Upload Files
File: //usr/share/bash-completion/completions/nc
# nc(1) completion                                         -*- shell-script -*-

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

    case $prev in
        -h|-I|-i|-O|-P|-p|-V|-w)
            return
            ;;
        -s)
            _ip_addresses
            return
            ;;
        -T)
            COMPREPLY=( $( compgen -W 'critical inetcontrol lowdelay netcontrol
                throughput reliability ef af{11..43} cs{0..7}' -- "$cur" ) )
            return
            ;;
        -X)
            COMPREPLY=( $( compgen -W '4 5 connect' -- "$cur" ) )
            return
            ;;
        -x)
            _known_hosts_real "$cur"
            return
            ;;
    esac

    if [[ "$cur" == -* ]]; then
        COMPREPLY=( $( compgen -W '$( _parse_help "$1" -h )' -- "$cur" ) )
        return
    fi

    # Complete 1st non-option arg only
    local i
    for (( i=1; i < cword; i++ )); do
        [[ ${words[i]} != -* && ${words[i-1]} != -[IiOPpsTVwXx] ]] && return
    done

    _known_hosts_real "$cur"
} &&
complete -F _nc nc

# ex: filetype=sh