nirc-rs/completions/nirc.fish

127 lines
5.7 KiB
Fish
Executable File

# nirc-rs fish completion for 0.5.0
# Disable file completions unless we explicitly want them
complete -c nirc -f
complete -c nirc-rs -f
# --help and --version
complete -c nirc -s h -l help -d 'Print usage information'
complete -c nirc -s V -l version -d 'Print version'
complete -c nirc -s c -l config -r -F -d 'Alternate configuration file'
# ═══ Connection ═══
complete -c nirc -k -x -a connect -d 'Connect to a server'
complete -c nirc -k -x -a disconnect -d 'Disconnect from protocol'
complete -c nirc -k -x -a newconn -d 'New connection dialog'
complete -c nirc -k -x -a server -d 'Switch servers'
# After /connect, offer protocols
complete -c nirc -k -x -a '/connect irc' -d 'Connect via IRC'
complete -c nirc -k -x -a '/connect matrix' -d 'Connect via Matrix'
complete -c nirc -k -x -a '/connect adc' -d 'Connect via ADC/DC++'
complete -c nirc -k -x -a '/connect dc' -d 'Connect via DC++'
complete -c nirc -k -x -a '/connect bitchat' -d 'Connect via BitChat P2P'
complete -c nirc -k -x -a '/connect revolt' -d 'Connect via Revolt'
# ═══ Messaging ═══
complete -c nirc -k -x -a msg -d 'Send private message'
complete -c nirc -k -x -a me -d 'Send action'
complete -c nirc -k -x -a say -d 'Send to current window'
complete -c nirc -k -x -a notice -d 'Send notice'
complete -c nirc -k -x -a ctcp -d 'Send CTCP query'
complete -c nirc -k -x -a raw -d 'Send raw IRC line'
complete -c nirc -k -x -a quote -d 'Alias for /raw'
complete -c nirc -k -x -a echo -d 'Display text'
# ═══ Channels ═══
complete -c nirc -k -x -a join -d 'Join channel'
complete -c nirc -k -x -a part -d 'Leave channel'
complete -c nirc -k -x -a names -d 'List channel users'
complete -c nirc -k -x -a topic -d 'View/set topic'
complete -c nirc -k -x -a invite -d 'Invite user'
complete -c nirc -k -x -a list -d 'List channels'
complete -c nirc -k -x -a who -d 'List users'
complete -c nirc -k -x -a whois -d 'User information'
# ═══ Channel ops ═══
complete -c nirc -k -x -a kick -d 'Kick user'
complete -c nirc -k -x -a op -d 'Give operator status'
complete -c nirc -k -x -a deop -d 'Remove operator status'
complete -c nirc -k -x -a mode -d 'Set mode'
# ═══ IRC operator ═══
complete -c nirc -k -x -a oper -d 'Become IRC operator'
complete -c nirc -k -x -a kill -d 'Force-disconnect user'
complete -c nirc -k -x -a kline -d 'Set K-line ban'
complete -c nirc -k -x -a unkline -d 'Remove K-line ban'
complete -c nirc -k -x -a wallops -d 'Message to operators'
# ═══ User ═══
complete -c nirc -k -x -a nick -d 'Change nickname'
complete -c nirc -k -x -a away -d 'Set away status'
complete -c nirc -k -x -a ignore -d 'Toggle ignore'
complete -c nirc -k -x -a unblock -d 'Remove from ignore list'
# ═══ Files ═══
complete -c nirc -k -x -a sendfile -d 'Send file'
complete -c nirc -k -x -a acceptfile -d 'Accept file transfer'
complete -c nirc -k -x -a listtransfers -d 'Toggle transfer panel'
# ═══ Windows ═══
complete -c nirc -k -x -a win -d 'Switch/list windows'
complete -c nirc -k -x -a jump -d 'Jump to window'
complete -c nirc -k -x -a jumpback -d 'Previous window'
complete -c nirc -k -x -a close -d 'Close window'
complete -c nirc -k -x -a open -d 'Open query window'
complete -c nirc -k -x -a winlist -d 'Toggle winlist'
# ═══ Utilities ═══
complete -c nirc -k -x -a set -d 'Set variable'
complete -c nirc -k -x -a get -d 'Print variable'
complete -c nirc -k -x -a alias -d 'Define alias'
complete -c nirc -k -x -a unalias -d 'Remove alias'
complete -c nirc -k -x -a bind -d 'Bind key'
complete -c nirc -k -x -a unbind -d 'Remove key binding'
complete -c nirc -k -x -a eval -d 'Expand and re-evaluate'
complete -c nirc -k -x -a source -d 'Execute command file'
complete -c nirc -k -x -a clear -d 'Clear tab'
complete -c nirc -k -x -a clearall -d 'Clear all tabs'
complete -c nirc -k -x -a save -d 'Save config'
complete -c nirc -k -x -a help -d 'Show help'
complete -c nirc -k -x -a quit -d 'Quit'
# ═══ Matrix ═══
complete -c nirc -k -x -a '/matrix login' -d 'Matrix password login'
complete -c nirc -k -x -a '/matrix logout' -d 'Matrix logout'
complete -c nirc -k -x -a '/matrix create' -d 'Create room'
complete -c nirc -k -x -a '/matrix invite' -d 'Invite user'
complete -c nirc -k -x -a '/matrix members' -d 'List members'
complete -c nirc -k -x -a '/matrix whoami' -d 'Show user info'
complete -c nirc -k -x -a '/matrix devices' -d 'List devices'
complete -c nirc -k -x -a '/matrix verify' -d 'SAS verification'
complete -c nirc -k -x -a '/matrix verify-confirm' -d 'Confirm SAS'
complete -c nirc -k -x -a '/matrix verify-cancel' -d 'Cancel SAS'
complete -c nirc -k -x -a '/matrix react' -d 'React to message'
complete -c nirc -k -x -a '/matrix reply' -d 'Reply to event'
complete -c nirc -k -x -a '/matrix backfill' -d 'Backfill messages'
# ═══ ADC/DC++ ═══
complete -c nirc -k -x -a '/adc search' -d 'Search hub files'
complete -c nirc -k -x -a '/adc users' -d 'List hub users'
complete -c nirc -k -x -a '/adc broadcast' -d 'Broadcast message'
complete -c nirc -k -x -a '/dc bcast' -d 'Broadcast message'
complete -c nirc -k -x -a '/adc get' -d 'Download file'
complete -c nirc -k -x -a '/adc download' -d 'Download file'
complete -c nirc -k -x -a '/adc dl' -d 'Download file'
# ═══ Revolt ═══
complete -c nirc -k -x -a '/revolt join' -d 'Join server'
complete -c nirc -k -x -a '/revolt leave' -d 'Leave server'
complete -c nirc -k -x -a '/revolt members' -d 'List members'
# ═══ BitChat P2P ═══
complete -c nirc -k -x -a '/bitchat peers' -d 'List P2P peers'
complete -c nirc -k -x -a '/p2p peers' -d 'List P2P peers'
complete -c nirc -k -x -a '/bitchat dm' -d 'Send DM'
complete -c nirc -k -x -a '/bitchat send' -d 'Send file via P2P'
complete -c nirc -k -x -a '/bitchat sendfile' -d 'Send file via P2P'