From d81ae2665fb7ff5123d8472e1d40d7d57fb4b291 Mon Sep 17 00:00:00 2001 From: Max Gonzih Date: Sun, 2 Feb 2014 16:22:18 +0300 Subject: [PATCH] Check for command-not-found command on suse --- share/functions/__fish_config_interactive.fish | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/share/functions/__fish_config_interactive.fish b/share/functions/__fish_config_interactive.fish index e92928621..a7204c02b 100644 --- a/share/functions/__fish_config_interactive.fish +++ b/share/functions/__fish_config_interactive.fish @@ -239,7 +239,8 @@ function __fish_config_interactive -d "Initializations that should be performed # First check if we are on OpenSUSE since SUSE's handler has no options # and expects first argument to be a command and second database - if test -f /etc/SuSE-release + # also check if there is command-not-found command. + if begin; test -f /etc/SuSE-release; and test -f /usr/bin/command-not-found; end function __fish_command_not_found_handler --on-event fish_command_not_found /usr/bin/command-not-found $argv end