diff options
| author | Jacob McDonnell <jacob@simplelittledream.com> | 2023-01-19 19:42:29 -0500 |
|---|---|---|
| committer | Jacob McDonnell <jacob@simplelittledream.com> | 2023-01-19 19:42:29 -0500 |
| commit | 1135ed7b98574797f6e6b99eb1604d42afff5059 (patch) | |
| tree | d295236c3e1d2c80bf4a1ff39bafacb20adf496a /.local/bin/internet | |
| parent | 26334cc3cf49a3e1afb1eb5a40599bb97cc3b5f1 (diff) | |
| parent | 56919b86e5e8612e3cf432eb5b9a110f4526f0eb (diff) | |
Merge branch 'macOS' of github.com:JacobMcDonnell/dotfiles into macOS
Diffstat (limited to '.local/bin/internet')
| -rwxr-xr-x | .local/bin/internet | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/.local/bin/internet b/.local/bin/internet index 70e48ec..942eefe 100755 --- a/.local/bin/internet +++ b/.local/bin/internet @@ -2,9 +2,9 @@ [ "$(connmanctl services | grep "Wired" | awk -F' ' '{print $2}')" = "Wired" ] && CONNECTION="Wired" || CONNECTION="$(connmanctl services | grep '*' | awk -F' ' '{print $2}')" -[ "$CONNECTION" = "Wired" ] && IP="$(ip address | grep dynamic | grep 192.168.)" || IP="$(ip address | grep wlo | grep 192.168. )" +[ "$CONNECTION" = "Wired" ] && IP="$(ip address | grep eth0 | grep 192.168.)" || IP="$(ip address | grep wlo | grep 192.168. )" IP="${IP%/*}" IP="${IP##* }" -printf $CONNECTION +echo $CONNECTION $IP |
