summary refs log tree commit diff
path: root/Completion/Unix/Command/_seafile
blob: bd36c0ac8ab1141b6c09a988fb2a9bb17d8560ec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#compdef seaf-cli

local -a commands

commands=(
  "init\:'initialize config directory'"
  "start\:'start seafile daemon'"
  "stop\:'stop seafile daemon'"
  "list\:'list local libraries'"
  "list-remote\:'list remote libraries'"
  "status\:'show syncing status'"
  "download\:'download a library from seafile server'"
  "download-by-name\:'download a library defined by name from seafile server'"
  "sync\:'sync a library with an existing foler'"
  "desync\:'desync a library with seafile server'"
  "create\:'create a library'"
  "config\:'configure seafile client'"
)

_arguments \
  ":command:(($commands))" \
  {-h,--help}'[show help]' \
  {-c,--confdir}'[specify config directory]:config directory:_files -/' \
  {-d,--dir,--folder}'[directory]:directory:_directories' \
  {-s,--server}'[URL for seafile server]':server \
  {-u,--username}'[username]':username \
  {-p,--password}'[password]':password \
  {-a,--tfa}'[two-factor authentication]':tfa \
  {-l,--library}'[library id]':library \
  {-e,--libpasswd}'[library password]':libpasswd \
  {-k,--key}'[configuration key]':key \
  {-v,--value}'[configuration value]':value \
  "*: :_files"