Added tcpdump lexer

Some indentation fixes
This commit is contained in:
Jesse Portnoy
2025-03-25 15:49:23 +00:00
parent 09ec4f4a7f
commit bf17668d56
4 changed files with 38 additions and 21 deletions
+16
View File
@@ -0,0 +1,16 @@
---
filetype: tcpdump
detect:
filename: "\\.tcpdump$"
rules:
- yellow: "\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.([0-9]+|[a-z]+)"
- constant.number: "(\\[[^]]+\\])"
- preproc: "([0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3})"
- cyan: "^(\\d+):(\\d+):(\\d+)"
- red: "(\\s+\\d+)/(\\w+).*"
- magenta: "options\\s\\[.*\\].*"
- magenta: "\\s+([a-zA-Z-]+)$"
- comment: "\\s(seq|ack|win|IP)\\s"
- yellow: "\\s+([a-z-]+\\.)?[a-z-]+\\.[a-z-]+\\.[a-z-]+"