Syntax highlighting for THOR APT Scanner text log files.
| Dark Theme | Light Theme |
|---|---|
![]() |
![]() |
Add this line to your ~/.vimrc (between call plug#begin() and call plug#end()):
Plug 'Nextron-Labs/thor-syntax-highlighting'Then restart Vim and run :PlugInstall.
To update after changes:
:PlugUpdateAdd this to your plugin list in ~/.config/nvim/lua/plugins.lua (or equivalent):
{ "Nextron-Labs/thor-syntax-highlighting" }Then restart Neovim or run :Lazy sync.
Add this line to your ~/.vimrc (between call vundle#begin() and call vundle#end()):
Plugin 'Nextron-Labs/thor-syntax-highlighting'Then restart Vim and run :PluginInstall.
Copy the files to your Vim runtime directory:
# Vim
mkdir -p ~/.vim/syntax ~/.vim/ftdetect
cp vim/syntax/thorlog.vim ~/.vim/syntax/
cp vim/ftdetect/thorlog.vim ~/.vim/ftdetect/
# Neovim
mkdir -p ~/.config/nvim/syntax ~/.config/nvim/ftdetect
cp vim/syntax/thorlog.vim ~/.config/nvim/syntax/
cp vim/ftdetect/thorlog.vim ~/.config/nvim/ftdetect/The filetype detection automatically activates for:
- Files with extensions
.thor.logor.thor.txt - Files matching
*_thor_*or*_THOR_*patterns (e.g.ion.local_thor_2026-01-21_1914.txt) - Any
.logor.txtfile whose first 20 lines containTHOR:orTHOR_UTIL:followed by a log level
To force the syntax on any file:
:set filetype=thorlog| Element | Highlight Group | Default Color |
|---|---|---|
| Timestamps | thorTimestamp → Number |
Magenta/Yellow |
| Hostnames | thorHost → Identifier |
Cyan |
| Hostname/IP | thorHost + thorHostIP → Constant |
Cyan + Red/Magenta |
Source (THOR:) |
thorSource → Keyword |
Yellow |
| Alert | thorLevelAlert |
🔴 Red (bold) |
| Error | thorLevelError |
🟣 Purple |
| Warning | thorLevelWarning |
🟡 Yellow |
| Notice | thorLevelNotice |
🔵 Blue |
| Info | thorLevelInfo |
🟢 Green |
| Field keys | thorFieldKey → Type |
Green |
| Hashes | thorHash* → Special |
Magenta |
| IP addresses | thorIPAddress → Constant |
Red/Magenta |
| Scan IDs | thorScanID → Constant |
Red/Magenta |
| Numbers | thorNumber → Number |
Magenta/Yellow |
Colors adapt to your colorscheme. The syntax uses standard Vim highlight groups with explicit fallback colors for log levels.

