diff --git a/lua/kulala/globals/init.lua b/lua/kulala/globals/init.lua index de973149..5472ab3c 100644 --- a/lua/kulala/globals/init.lua +++ b/lua/kulala/globals/init.lua @@ -2,7 +2,7 @@ local FS = require("kulala.utils.fs") local M = {} -M.VERSION = "2.2.0" +M.VERSION = "2.2.1" M.UI_ID = "kulala://ui" M.HEADERS_FILE = FS.get_plugin_tmp_dir() .. "/headers.txt" M.BODY_FILE = FS.get_plugin_tmp_dir() .. "/body.txt" diff --git a/lua/kulala/parser/init.lua b/lua/kulala/parser/init.lua index c759f9e7..13e9c129 100644 --- a/lua/kulala/parser/init.lua +++ b/lua/kulala/parser/init.lua @@ -124,11 +124,11 @@ M.get_document = function() if is_request_line == false then is_body_section = true end - elseif line:match("^@%w+") then + elseif line:match("^@([%w_]+)") then -- Variable -- Variables are defined as `@variable_name=value` -- The value can be a string, a number or boolean - local variable_name, variable_value = line:match("^%@(%w+)%s*=%s*(.*)$") + local variable_name, variable_value = line:match("^@([%w_]+)%s*=%s*(.*)$") if variable_name and variable_value then -- remove the @ symbol from the variable name variable_name = variable_name:sub(1) diff --git a/package.json b/package.json index e798d140..aa5afc4d 100644 --- a/package.json +++ b/package.json @@ -1,4 +1,4 @@ { "name": "kulala.nvim", - "version": "2.2.0" + "version": "2.2.1" }