From 10b38aec5b7b10b5b5481846d8e085d7f62c7887 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Sun, 9 Oct 2016 23:02:57 -0700 Subject: [PATCH] [Shell] Fix localip command --- dotfiles/lib/shellenv/functions.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dotfiles/lib/shellenv/functions.sh b/dotfiles/lib/shellenv/functions.sh index aecd923f..eb294624 100644 --- a/dotfiles/lib/shellenv/functions.sh +++ b/dotfiles/lib/shellenv/functions.sh @@ -450,6 +450,5 @@ function which_readlink { } function localip { - command_exists ip && ip addr show - alias localip="ifconfig | grep -Eo 'inet (addr:)?([0-9]*\.){3}[0-9]*' | grep -Eo '([0-9]*\.){3}[0-9]*' | grep -v '127.0.0.1'" + command_exists ip && ip addr show || ifconfig | grep -Eo 'inet (addr:)?([0-9]*\.){3}[0-9]*' | grep -Eo '([0-9]*\.){3}[0-9]*' | grep -v '127.0.0.1' }