46 lines
3.2 KiB
Bash
46 lines
3.2 KiB
Bash
zmodload -i zsh/complist
|
|
|
|
WORDCHARS='-_'
|
|
|
|
unsetopt menu_complete
|
|
unsetopt flowcontrol
|
|
setopt auto_menu
|
|
setopt complete_in_word
|
|
setopt always_to_end
|
|
setopt auto_cd
|
|
setopt multios
|
|
setopt prompt_subst
|
|
setopt auto_pushd
|
|
setopt pushd_ignore_dups
|
|
setopt pushdminus
|
|
|
|
zstyle ':completion:*:*:*:*:*' menu select
|
|
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}' 'r:|=*' 'l:|=* r:|=*'
|
|
zstyle ':completion:*' special-dirs true
|
|
|
|
zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
|
|
|
|
zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#) ([0-9a-z-]#)*=01;34=0=01'
|
|
|
|
zstyle ':completion:*:*:*:*:processes' command "ps -u $USER -o pid,user,comm -w -w"
|
|
|
|
zstyle ':completion:*:cd:*' tag-order local-directories directory-stack path-directories
|
|
|
|
zstyle ':completion:*' use-cache yes
|
|
zstyle ':completion:*' cache-path "$HOME/.cache/zsh/compcache/"
|
|
|
|
zstyle ':completion:*:*:*:users' ignored-patterns adm amanda apache at avahi avahi-autoipd backup beaglidx bin bitcoin bitwarden_rs cacti canna clamav ceph colord consul couchdb cups daemon dbus Debian-exim debian-tor dhcp dhcpcd distcache dnsdist dnsmasq dovecot eeleater elasticsearch epmd fax flatpak flaskdemo ftp games gdm geoclue git gitea gkrellmd glances gluster gopher gophernicus gnats hacluster haldaemon halt hsqldb http ident irc junkbust kdm kibana landscape ldap lightdm list lldpd logstash lp lxd mail mailman mailnull man mattermost messagebus mldonkey mongodb mxisd mysql nagios named netdata netdump news nfsnobody nm-openvpn nm-openconnect nobody nscd ntp nut nvidia-persistenced nweger nx obsrun openvpn operator pcap pcp polkitd pollinate postfix postgres powerdns privoxy proxy pulse prosody puppet pvm quagga radiusd radvd redis rpc rpcuser rpm rtkit root saned scard sddm shutdown smmsp squid sshd statd strongswan stunnel svn synapse sync sys syslog systemd-coredump systemd-journal-remote systemd-network systemd-resolve systemd-timesync tcpdump teamspeak test tftp tinyproxy tor transmission tss turnserver usbmux unbound uucp uuidd vault vcsa webvirtmgr wildfly wwwrun www-data xfs xrdp youtrack zabbix-agent zabbix-server zabbix zerotier-one zerotier '_*'
|
|
|
|
zstyle '*' single-ignored show
|
|
|
|
zstyle -e ':completion:*:(ssh|scp|sftp|rsh|rsync):hosts' hosts 'reply=(${=${${(f)"$(cat {/etc/ssh_,~/.ssh/known_}hosts(|2)(N) /dev/null)"}%%[# ]*}//,/ })'
|
|
zstyle ':completion:*:(scp|rsync):*' tag-order 'hosts:-host:host hosts:-domain:domain hosts:-ipaddr:ip\ address *'
|
|
zstyle ':completion:*:(scp|rsync):*' group-order users files all-files hosts-domain hosts-host hosts-ipaddr
|
|
zstyle ':completion:*:ssh:*' tag-order users 'hosts:-host:host hosts:-domain:domain hosts:-ipaddr:ip\ address *'
|
|
zstyle ':completion:*:ssh:*' group-order hosts-domain hosts-host users hosts-ipaddr
|
|
zstyle ':completion:*:(ssh|scp|rsync):*:hosts-host' ignored-patterns '*(.|:)*' loopback ip6-loopback localhost ip6-localhost broadcasthost megumi _gateway pxm
|
|
zstyle ':completion:*:(ssh|scp|rsync):*:hosts-domain' ignored-patterns '<->.<->.<->.<->' '^[-[:alnum:]]##(.[-[:alnum:]]##)##' '*@*' '*.eeleater.org' '*sublime*' '*.local'
|
|
zstyle ':completion:*:(ssh|scp|rsync):*:hosts-ipaddr' ignored-patterns '^(<->.<->.<->.<->|(|::)([[:xdigit:].]##:(#c,2))##(|%*))' '127.0.0.<->' '255.255.255.255' '::1' 'fe80::*'
|
|
|
|
autoload -U +X bashcompinit
|
|
bashcompinit
|