From c148b97f5cf22080cc85fd730db6739e822f2aba Mon Sep 17 00:00:00 2001 From: Petar Kirov Date: Wed, 23 Jan 2019 04:22:17 +0200 Subject: [PATCH] fish_greeting.fish: Make existance of uptime command optional (#189) The `uptime` command does not exist in some environments, such as MSYS2, so execute the command only if it exists. --- fish_greeting.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fish_greeting.fish b/fish_greeting.fish index c5f1a44..3b1ad83 100644 --- a/fish_greeting.fish +++ b/fish_greeting.fish @@ -1,6 +1,6 @@ function fish_greeting -d "What's up, fish?" set_color $fish_color_autosuggestion uname -nmsr - uptime + command -q -s uptime; and uptime set_color normal end