4 ms·
I'm on my phone but I think you can do this if you're using awk anyway: netstat -rn -f inet | awk '/default/ {print $2;exit}'
by mzi 5y ago
I'm on my phone but I think you can do this if you're using awk anyway:
netstat -rn -f inet | awk '/default/ {print $2;exit}'