On 8/10/20 3:36 PM, Garry T. Williams wrote:
On Monday, August 10, 2020 5:46:54 PM EDT Mike Wright wrote:
alias gateways="ip route list | awk '/^default/ {print}'"

That is the same as

     ip route list | grep ^default

In general,

     ... | awk '/foo/ {print}'

is equivalent to

     ... | grep foo


True. But grep is almost double the size and mawk is a byte code interpreter for awk (fast). Either will work (plus I've just been learning about awk and HAD to share )

:m
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org

Reply via email to