Timeline for Why does grep not find MAC addresses and host names in Linux?
Current License: CC BY-SA 4.0
8 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Dec 31, 2023 at 22:45 | history | edited | FKEinternet | CC BY-SA 4.0 | allows whitespace after the hostname, explained end-of-line test *is* required |
| Dec 31, 2023 at 22:30 | history | rollback | FKEinternet | Rollback to Revision 2 | |
| Dec 29, 2023 at 12:13 | history | edited | ilkkachu | CC BY-SA 4.0 | better remove the ending delimiter too |
| Dec 28, 2023 at 21:04 | history | edited | FKEinternet | CC BY-SA 4.0 | thanks, and illustrate the corrected string |
| Dec 28, 2023 at 19:05 | comment | added | Jörg W Mittag | Your regex says that the line should start with /^ and end with $/i, which it obviously does not. | |
| Dec 28, 2023 at 10:47 | answer | added | Sotto Voce | timeline score: 4 | |
| Dec 28, 2023 at 5:39 | comment | added | cutrightjm | What about this one? cat mac-hosts | grep -P -c '^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2}) [0-9A-Za-z].*$' | |
| Dec 28, 2023 at 3:54 | history | asked | FKEinternet | CC BY-SA 4.0 |