Lua port of syntax highlighting for Hurl
use 'samueljoli/hurl.nvim'Plug 'samueljoli/hurl.nvim'This plugin allows you to customize several syntax match rules as originally defined by hurl. If no configuration is provided, the plugin will use your colorscheme's default highlight groups.
Example:
use {
'samueljoli/hurl.nvim',
config = function()
require('hurl').setup({
comment = "#ebc021", -- default => Comment
method = "#fffc58", -- default => Statement
url = "#fffc58", -- default => Underlined
version = "#032ea7", -- default => Statement
status = "#032ea7", -- default => Number
section = "#032ea7", -- default => Statement
operators = "#c592ff", -- default => Operator
string = "#032ea7", -- default => String
query = "#d57bff", -- default => Identifier
filter = "#032ea7", -- default => Operator
predicate = "#032ea7", -- default => Operator
template = "#032ea7", -- default => Identifier
escapeQuote = "#032ea7", -- default => SpecialChar
escapeNumberSign = "#032ea7", -- default => SpecialChar
})
end
}List of supported syntax match rules:
commentmethodGETPOSTPUTPATCHDELETECONNECTOPTIONSTRACELINKUNLINKPURGELOCKUNLOCKPROPFINDVIEW
urlversionHTTPHTTP/1.0HTTP/1.1HTTP/2HTTP/*
status[0-9]
section[Asserts][Captures][Cookies][FormParams][MultipartFormData][Options][QueryStringParams]
operators==!=>>=<<=
stringquerystatusurlheadercookiebodyjsonpathxpathregexvariabledurationsha256md5bytes
🚨 If an invalid hex code is passed, the plugin will use the fallback syntax match rule and log the key-value pair to the console. To view the log, check Vim's :messages.