Browse Source

New shell completions for borg 1.1.9

SanskritFritz 6 years ago
parent
commit
0a97274bd1

+ 2 - 2
scripts/shell_completions/bash/borg

@@ -12,7 +12,7 @@ _borg()
     local cur="${COMP_WORDS[COMP_CWORD]}"
     local prev="${COMP_WORDS[COMP_CWORD-1]}"
     local prevprev="${COMP_WORDS[COMP_CWORD-2]}"
-    local common_opts="-h --help --version --critical --error --warning --info -v --verbose --debug --debug-topic -p --progress --log-json --lock-wait --show-version --show-rc --umask --remote-path --remote-ratelimit --consider-part-files --debug-profile"
+    local common_opts="-h --help --version --critical --error --warning --info -v --verbose --debug --debug-topic -p --progress --log-json --lock-wait --show-version --show-rc --umask --remote-path --remote-ratelimit --consider-part-files --debug-profile --rsh"
     local opts="${common_opts}"
 
     # Commands
@@ -72,7 +72,7 @@ _borg()
     if [[ ${cur} == -* ]] ; then
         case "${COMP_LINE}" in
             *' init '*)
-                local opts="-e --encryption --append-only --storage-quota ${common_opts}"
+                local opts="-e --encryption --append-only --storage-quota --make-parent-dirs ${common_opts}"
                 ;;
             *' create '*)
                 local opts="-n --dry-run -s --stats --list --filter --json --no-cache-sync --stdin-name -e --exclude --exclude-from --pattern --patterns-from --exclude-caches --exclude-if-present --keep-exclude-tags --keep-tag-files --exclude-nodump -x --one-file-system --numeric-owner --noatime --noctime --nobirthtime --nobsdflags --ignore-inode --files-cache --read-special --comment --timestamp -c --checkpoint-interval --chunker-params -C --compression ${common_opts}"

+ 2 - 0
scripts/shell_completions/fish/borg.fish

@@ -82,12 +82,14 @@ complete -c borg         -l 'remote-path'           -d 'Use PATH as remote borg
 complete -c borg -f      -l 'remote-ratelimit'      -d 'Set remote network upload RATE limit'
 complete -c borg -f      -l 'consider-part-files'   -d 'Treat part files like normal files'
 complete -c borg         -l 'debug-profile'         -d 'Write execution profile into FILE'
+complete -c borg         -l 'rsh'                   -d 'Use COMMAND instead of ssh'
 
 # borg init options
 set -l encryption_modes "none keyfile keyfile-blake2 repokey repokey-blake2 authenticated authenticated-blake2"
 complete -c borg -f -s e -l 'encryption'            -d 'Encryption key MODE' -a "$encryption_modes" -n "__fish_seen_subcommand_from init"
 complete -c borg -f      -l 'append-only'           -d 'Create an append-only mode repository'      -n "__fish_seen_subcommand_from init"
 complete -c borg -f      -l 'storage-quota'         -d 'Set storage QUOTA of the repository'        -n "__fish_seen_subcommand_from init"
+complete -c borg -f      -l 'make-parent-dirs'      -d 'Create parent directories'                  -n "__fish_seen_subcommand_from init"
 
 # borg create options
 complete -c borg -f -s n -l 'dry-run'               -d 'Do not change the repository'               -n "__fish_seen_subcommand_from create"

+ 3 - 1
scripts/shell_completions/zsh/_borg

@@ -55,7 +55,8 @@ _borg() {
                              --remote-path'[set remote path to executable (default: "borg")]:_files'
                              --remote-ratelimit'[set remote network upload rate limit in kiByte/s (default: 0=unlimited)]:RATE'
                              --consider-part-files'[treat part files like normal files (e.g. to list/extract them)]'
-                             --debug-profile'[Write execution profile in Borg format into FILE.]:_files')
+                             --debug-profile'[write execution profile in Borg format into FILE.]:_files'
+                             --rsh'[use COMMAND instead of ssh]:COMMAND')
 
     borg_possible_commands=(init create extract check rename list diff delete prune info mount umount key upgrade recreate export-tar serve config with-lock break-lock benchmark help)
     borg_possible_key_commands=(change-passphrase import export)
@@ -74,6 +75,7 @@ _borg() {
                 {-e,--encryption}'[select encryption key mode]:MODE'\
                 --append-only'[only allow appending to repository segment files]'\
                 --storage-quota'[Override storage quota of the repository]:QUOTA'\
+                --make-parent-dirs'[create parent directories]'\
                 $borg_common_options
             ;;
         (create)