From 5446841069beb323f7237de1215e46cc70cf9440 Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Sun, 28 Feb 2016 18:05:16 +0100 Subject: [PATCH] Ditch __fish_sgrep in obnam completions --- share/completions/obnam.fish | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/share/completions/obnam.fish b/share/completions/obnam.fish index 68d324d79..53fe5a2ef 100644 --- a/share/completions/obnam.fish +++ b/share/completions/obnam.fish @@ -1,9 +1,10 @@ function nocommand - if commandline | __fish_sgrep -qe "add-key\|backup\|client-keys\|clients\|diff\|dump-repo\|force-lock\|forget\|fsck\|generations\|genids\|list-keys\|list-toplevels\|ls\|mount\|nagios-last-backup-age\|remove-client\|remove-key\|restore\|verify" + if __fish_seen_subcommand_from add-key backup client-keys clients diff \ + dump-repo force-lock forget fsck generations genids list-keys list-toplevels ls mount nagios-last-backup-age remove-client remove-key restore verify return 1 - end - return 0 + end + return 0 end complete --command obnam --no-files --condition nocommand --arguments 'add-key' --description 'Adds an encryption key to the repository'