diff --git a/plugins/command-not-found/command-not-found.plugin.zsh b/plugins/command-not-found/command-not-found.plugin.zsh index 5ab03d5a9..0e2684171 100644 --- a/plugins/command-not-found/command-not-found.plugin.zsh +++ b/plugins/command-not-found/command-not-found.plugin.zsh @@ -2,4 +2,6 @@ # as seen in http://www.porcheron.info/command-not-found-for-zsh/ # this is installed in Ubuntu -source /etc/zsh_command_not_found +if [[ -f "/etc/zsh_command_not_found" ]]; then + source /etc/zsh_command_not_found +fi