mirror of
https://github.com/shadowsocks/shadowsocks-libev.git
synced 2026-11-17 01:54:02 +00:00
Add zsh completion scripts
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
#compdef ss-local
|
||||
|
||||
local ciphers
|
||||
ciphers='(rc4-md5 aes-128-gcm aes-192-gcm aes-256-gcm aes-128-cfb aes-192-cfb aes-256-cfb aes-128-ctr aes-192-ctr aes-256-ctr camellia-128-cfb camellia-192-cfb camellia-256-cfb bf-cfb chacha20-ietf-poly1305 salsa20 chacha20 chacha20-ietf)'
|
||||
|
||||
_arguments "-h::" \
|
||||
"-s:server host:_hosts" \
|
||||
"-p:server port:" \
|
||||
"-l:local port:" \
|
||||
"-k:password:" \
|
||||
"-m:encrypt method:$ciphers" \
|
||||
"-a:run as user:_users" \
|
||||
"-f:pid file:_files" \
|
||||
"-t:timeout:" \
|
||||
"-c:configure file:_files" \
|
||||
"-n:max number of open files:" \
|
||||
"-i:bind interface:_net_interfaces" \
|
||||
"-b:local address:(127.0.0.1 \:\:1 0.0.0.0 \:\:)" \
|
||||
"-u:enable udp:" \
|
||||
"-U:udp only:" \
|
||||
"-v:verbose mode:" \
|
||||
"--reuse-port::" \
|
||||
"--fast-open::" \
|
||||
"--acl:acl file:_files" \
|
||||
"--mtu::" \
|
||||
"--mptcp::" \
|
||||
"--key:key in base64:" \
|
||||
"--plugin:plugin name:" \
|
||||
"--plugin-opts:plugin options:" \
|
||||
"--help::"
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
#compdef ss-manager
|
||||
|
||||
local ciphers
|
||||
ciphers='(rc4-md5 aes-128-gcm aes-192-gcm aes-256-gcm aes-128-cfb aes-192-cfb aes-256-cfb aes-128-ctr aes-192-ctr aes-256-ctr camellia-128-cfb camellia-192-cfb camellia-256-cfb bf-cfb chacha20-ietf-poly1305 salsa20 chacha20 chacha20-ietf)'
|
||||
|
||||
_arguments "-h::" \
|
||||
"-s:server host:_hosts" \
|
||||
"-p:server port:" \
|
||||
"-l:local port:" \
|
||||
"-k:password:" \
|
||||
"-m:encrypt method:$ciphers" \
|
||||
"-a:run as user:_users" \
|
||||
"-f:pid file:_files" \
|
||||
"-t:timeout:" \
|
||||
"-c:configure file:_files" \
|
||||
"-n:max number of open files:" \
|
||||
"-i:bind interface:_net_interfaces" \
|
||||
"-b:local address:(127.0.0.1 \:\:1 0.0.0.0 \:\:)" \
|
||||
"-u:enable udp:" \
|
||||
"-U:udp only:" \
|
||||
"-v:verbose mode:" \
|
||||
"--executable:path to ss-server:_files" \
|
||||
"--manager-address:manager address:" \
|
||||
"--reuse-port::" \
|
||||
"--acl:acl file:_files" \
|
||||
"--mtu::" \
|
||||
"--key:key in base64:" \
|
||||
"--plugin:plugin name:" \
|
||||
"--plugin-opts:plugin options:" \
|
||||
"--help::"
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
#compdef ss-redir
|
||||
|
||||
local ciphers
|
||||
ciphers='(rc4-md5 aes-128-gcm aes-192-gcm aes-256-gcm aes-128-cfb aes-192-cfb aes-256-cfb aes-128-ctr aes-192-ctr aes-256-ctr camellia-128-cfb camellia-192-cfb camellia-256-cfb bf-cfb chacha20-ietf-poly1305 salsa20 chacha20 chacha20-ietf)'
|
||||
|
||||
_arguments "-h::" \
|
||||
"-s:server host:_hosts" \
|
||||
"-p:server port:" \
|
||||
"-l:local port:" \
|
||||
"-k:password:" \
|
||||
"-m:encrypt method:$ciphers" \
|
||||
"-a:run as user:_users" \
|
||||
"-f:pid file:_files" \
|
||||
"-t:timeout:" \
|
||||
"-c:configure file:_files" \
|
||||
"-n:nofile:" \
|
||||
"-b:local address:(127.0.0.1 \:\:1 0.0.0.0 \:\:)" \
|
||||
"-u:enable udp:" \
|
||||
"-U:udp only:" \
|
||||
"-v:verbose mode:" \
|
||||
"--reuse-port::" \
|
||||
"--fast-open::" \
|
||||
"--acl:acl file:_files" \
|
||||
"--mtu::" \
|
||||
"--mptcp::" \
|
||||
"--key:key in base64:" \
|
||||
"--plugin:plugin name:" \
|
||||
"--plugin-opts:plugin options:" \
|
||||
"--help::"
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
#compdef ss-server
|
||||
|
||||
local ciphers
|
||||
ciphers='(rc4-md5 aes-128-gcm aes-192-gcm aes-256-gcm aes-128-cfb aes-192-cfb aes-256-cfb aes-128-ctr aes-192-ctr aes-256-ctr camellia-128-cfb camellia-192-cfb camellia-256-cfb bf-cfb chacha20-ietf-poly1305 salsa20 chacha20 chacha20-ietf)'
|
||||
|
||||
_arguments "-h::" \
|
||||
"-s:server host:_hosts" \
|
||||
"-p:server port:" \
|
||||
"-l:local port:" \
|
||||
"-k:password:" \
|
||||
"-m:encrypt method:$ciphers" \
|
||||
"-a:run as user:_users" \
|
||||
"-f:pid file:_files" \
|
||||
"-t:timeout:" \
|
||||
"-c:configure file:_files" \
|
||||
"-n:max number of open files:" \
|
||||
"-i:bind interface:_net_interfaces" \
|
||||
"-b:local address:(127.0.0.1 \:\:1 0.0.0.0 \:\:)" \
|
||||
"-u:enable udp:" \
|
||||
"-U:udp only:" \
|
||||
"-v:verbose mode:" \
|
||||
"-6:ipv6 first:" \
|
||||
"-d:nameserver for internal dns:" \
|
||||
"--manager-address:manager address:" \
|
||||
"--reuse-port::" \
|
||||
"--fast-open::" \
|
||||
"--acl:acl file:_files" \
|
||||
"--mtu::" \
|
||||
"--mptcp::" \
|
||||
"--key:key in base64:" \
|
||||
"--plugin:plugin name:" \
|
||||
"--plugin-opts:plugin options:" \
|
||||
"--help::"
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
#compdef ss-tunnel
|
||||
|
||||
local ciphers
|
||||
ciphers='(rc4-md5 aes-128-gcm aes-192-gcm aes-256-gcm aes-128-cfb aes-192-cfb aes-256-cfb aes-128-ctr aes-192-ctr aes-256-ctr camellia-128-cfb camellia-192-cfb camellia-256-cfb bf-cfb chacha20-ietf-poly1305 salsa20 chacha20 chacha20-ietf)'
|
||||
|
||||
_arguments "-h::" \
|
||||
"-s:server host:_hosts" \
|
||||
"-p:server port:" \
|
||||
"-l:local port:" \
|
||||
"-k:password:" \
|
||||
"-m:encrypt method:$ciphers" \
|
||||
"-a:run as user:_users" \
|
||||
"-f:pid file:_files" \
|
||||
"-t:timeout:" \
|
||||
"-c:configure file:_files" \
|
||||
"-n:nofile:" \
|
||||
"-i:bind interface:_net_interfaces" \
|
||||
"-b:local address:(127.0.0.1 \:\:1 0.0.0.0 \:\:)" \
|
||||
"-u:enable udp:" \
|
||||
"-U:udp only:" \
|
||||
"-v:verbose mode:" \
|
||||
"-L:destination server address and port:" \
|
||||
"--reuse-port::" \
|
||||
"--acl:acl file:_files" \
|
||||
"--mtu::" \
|
||||
"--key:key in base64:" \
|
||||
"--plugin:plugin name:" \
|
||||
"--plugin-opts:plugin options:" \
|
||||
"--help::"
|
||||
|
||||
Reference in New Issue
Block a user