#!/bin/bash

_friend() {


        local cur prev

        COMPREPLY=()

        cur="${COMP_WORDS[COMP_CWORD]}"

        prev="${COMP_WORDS[COMP_CWORD-1]}"


    COMPREPLY=( $( compgen -W 'hi bye' -- "$cur" ) )
}

complete -o nospace -o default -F _friend "friend" 
