Update shell completion scripts

This commit is contained in:
timvisee 2020-01-10 17:13:36 +01:00
parent a6656c06b2
commit 60a130ef2a
No known key found for this signature in database
GPG key ID: B8DB720BC383E172
5 changed files with 14 additions and 3 deletions

View file

@ -1104,6 +1104,8 @@ _arguments "${_arguments_options[@]}" \
'(-p --password)--gen-passphrase[Protect the file with a generated passphrase]' \
'-o[Open the share link in your browser]' \
'--open[Open the share link in your browser]' \
'-D[Delete local file after upload]' \
'--delete[Delete local file after upload]' \
'-a[Archive the upload in a single file]' \
'--archive[Archive the upload in a single file]' \
'(-C --copy-cmd)-c[Copy the share link to your clipboard]' \
@ -1157,6 +1159,8 @@ _arguments "${_arguments_options[@]}" \
'(-p --password)--gen-passphrase[Protect the file with a generated passphrase]' \
'-o[Open the share link in your browser]' \
'--open[Open the share link in your browser]' \
'-D[Delete local file after upload]' \
'--delete[Delete local file after upload]' \
'-a[Archive the upload in a single file]' \
'--archive[Archive the upload in a single file]' \
'(-C --copy-cmd)-c[Copy the share link to your clipboard]' \
@ -1210,6 +1214,8 @@ _arguments "${_arguments_options[@]}" \
'(-p --password)--gen-passphrase[Protect the file with a generated passphrase]' \
'-o[Open the share link in your browser]' \
'--open[Open the share link in your browser]' \
'-D[Delete local file after upload]' \
'--delete[Delete local file after upload]' \
'-a[Archive the upload in a single file]' \
'--archive[Archive the upload in a single file]' \
'(-C --copy-cmd)-c[Copy the share link to your clipboard]' \

View file

@ -390,6 +390,8 @@ Register-ArgumentCompleter -Native -CommandName 'ffsend' -ScriptBlock {
[CompletionResult]::new('--gen-passphrase', 'gen-passphrase', [CompletionResultType]::ParameterName, 'Protect the file with a generated passphrase')
[CompletionResult]::new('-o', 'o', [CompletionResultType]::ParameterName, 'Open the share link in your browser')
[CompletionResult]::new('--open', 'open', [CompletionResultType]::ParameterName, 'Open the share link in your browser')
[CompletionResult]::new('-D', 'D', [CompletionResultType]::ParameterName, 'Delete local file after upload')
[CompletionResult]::new('--delete', 'delete', [CompletionResultType]::ParameterName, 'Delete local file after upload')
[CompletionResult]::new('-a', 'a', [CompletionResultType]::ParameterName, 'Archive the upload in a single file')
[CompletionResult]::new('--archive', 'archive', [CompletionResultType]::ParameterName, 'Archive the upload in a single file')
[CompletionResult]::new('-c', 'c', [CompletionResultType]::ParameterName, 'Copy the share link to your clipboard')

View file

@ -2057,7 +2057,7 @@ _ffsend() {
return 0
;;
ffsend__u)
opts=" -P -o -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
opts=" -P -o -D -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --delete --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
return 0
@ -2148,7 +2148,7 @@ _ffsend() {
return 0
;;
ffsend__up)
opts=" -P -o -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
opts=" -P -o -D -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --delete --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
return 0
@ -2239,7 +2239,7 @@ _ffsend() {
return 0
;;
ffsend__upload)
opts=" -P -o -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
opts=" -P -o -D -a -c -C -S -Q -V -f -I -y -q -v -i -p -d -e -h -n -t -T -A -H --gen-passphrase --open --delete --archive --copy --copy-cmd --shorten --qrcode --help --version --force --no-interact --yes --quiet --verbose --incognito --password --download-limit --expiry-time --host --name --timeout --transfer-timeout --api --basic-auth --history <FILE>... "
if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
return 0

View file

@ -374,6 +374,8 @@ edit:completion:arg-completer[ffsend] = [@words]{
cand --gen-passphrase 'Protect the file with a generated passphrase'
cand -o 'Open the share link in your browser'
cand --open 'Open the share link in your browser'
cand -D 'Delete local file after upload'
cand --delete 'Delete local file after upload'
cand -a 'Archive the upload in a single file'
cand --archive 'Archive the upload in a single file'
cand -c 'Copy the share link to your clipboard'

View file

@ -180,6 +180,7 @@ complete -c ffsend -n "__fish_seen_subcommand_from upload" -l basic-auth -d 'HTT
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s H -l history -d 'Use the specified history file'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s P -l gen-passphrase -d 'Protect the file with a generated passphrase'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s o -l open -d 'Open the share link in your browser'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s D -l delete -d 'Delete local file after upload'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s a -l archive -d 'Archive the upload in a single file'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s c -l copy -d 'Copy the share link to your clipboard'
complete -c ffsend -n "__fish_seen_subcommand_from upload" -s C -l copy-cmd -d 'Copy the ffsend download command to your clipboard'