Created
October 3, 2015 21:18
-
-
Save jsz0/307074c0d462157d7c1d to your computer and use it in GitHub Desktop.
grc color enhancement for osx/ifconfig
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ipv4 addr | |
regexp=\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3} | |
colours=italic blue | |
====== | |
# ipv6 addr | |
regexp=(\b[0-9a-fA-F]{1,4}(\:\:?[0-9a-fA-F]{1,4})+|::1) | |
colours=italic blue | |
====== | |
# hwaddr | |
regexp=(\d|[a-f]){2}(\:(\d|[a-f]){2}){5} | |
colours=italic blue | |
======= | |
# interfaces | |
regexp=(^([a-z0-9]{2,}\d*):?\s|[%]([a-z0-9]{2,}\d*):?\s) | |
colours=bold cyan | |
====== | |
# netmask-hex | |
regexp=0[xX][0-9a-fA-F]+ | |
colours=italic blue | |
===== | |
# formatting | |
regexp=([<]|[>]|[,]|b[<]|[<]) | |
colours=dark green | |
====== | |
# formatting-group | |
regexp=([(]|[)]|[=]) | |
colours=yellow | |
====== | |
# digits-xxxx | |
regexp=([1-9][0-9][0-9][0-9]|[0-9]$|[0-9][x][0-9]$) | |
colours=italic magenta | |
===== | |
# keywords-top | |
regexp=(flags|options|ether|inet6?|nd6|lladdr|media[:]|status[:]|type[:]|link.quality[:]|state.availability[:]|link.rate[:]) | |
colours=green | |
====== | |
# keywords-inner | |
regexp=(netmask|broadcast|prefixlen|scopeid|mtu|autoselect|index) | |
colours=yellow | |
====== | |
# keywords-verbose | |
regexp=(eflags|scheduler[:]) | |
colours=green | |
===== | |
# values | |
regexp=(full-duplex|flow-control|unknown.type|1000baseT|RXCSUM|TXCSUM|VLAN_HWTAGGING|POINTOPOINT|BROADCAST|TXSTART|NOAUTOIPV6LL|LOOPBACK|MULTICAST|SMART|SIMPLEX|RUNNING|PERFORMNUD) | |
colours=italic magenta | |
====== | |
# values-verbose | |
regexp=(IP.over.FireWire$|[1-9][0-9][.][0-9][0-9].Mbps|[1-9][0-9][.][0-9][1-9].Gbps|[1-9][.][0-9][0-9].Gbps|true|Ethernet|ACCEPT_RTADV|RXPOLL|ARPLL|QFQ) | |
colours=italic magenta | |
===== | |
# mtu-lazy (fixup) | |
regexp=(1500$|16384$|4078$|1380$|1280$|64|128) | |
colours=italic magenta | |
===== | |
# notable | |
regexp=(UP|active$|good) | |
colours=italic green | |
====== | |
# notable-down | |
regexp=(DOWN|\040inactive$) | |
colours=red |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment