mirror of
https://github.com/omltcat/dcs-lua-runner.git
synced 2025-11-10 15:49:49 +00:00
Release 1.2.3
This commit is contained in:
parent
4e6054533b
commit
6c2b61d3dc
@ -117,3 +117,8 @@ All notable changes to the "dcs-lua-runner" extension will be documented in this
|
||||
|
||||
### Fixed
|
||||
- Handling of decimal number keys
|
||||
|
||||
## [1.2.3] - 2024-10-19
|
||||
|
||||
### Fixed
|
||||
- Handling of Lua table keys with more than one dot
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
"description": "Quickly run lua code in DCS World (local or remote server). A reimplementation of the DCS Fiddle lua console in VS Code.",
|
||||
"license": "MIT",
|
||||
"publisher": "omltcat",
|
||||
"version": "1.2.2",
|
||||
"version": "1.2.3",
|
||||
"icon": "docs/img/icon.png",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@ -65,8 +65,8 @@ async function runLua(lua: string, outputChannel: vscode.OutputChannel, filename
|
||||
// Replace JSON syntax with Lua syntax
|
||||
luaString = luaString.replace(/null/g, 'nil'); // Replace null with nil
|
||||
luaString = luaString.replace(/"((?:[^"\\]|\\.)+)":/g, '["$1"] ='); // Replace "key": with ["key"] =
|
||||
luaString = luaString.replace(/\["_([0-9.]+)"\]\s*=/g, '[$1] ='); // Replace ["_n"] or ["_n.m"] = with [n] or [n.m] =
|
||||
luaString = luaString.replace(/\["([0-9.]+)"\]\s*=/g, '[$1] ='); // Replace ["n"] or ["n.m"] = with [n] or [n.m] =
|
||||
luaString = luaString.replace(/\["_([0-9]+(?:\.[0-9]+)?)"\]\s*=/g, '[$1] ='); // Replace ["_n"] or ["_n.m"] = with [n] or [n.m] =
|
||||
luaString = luaString.replace(/\["([0-9]+(?:\.[0-9]+)?)"\]\s*=/g, '[$1] ='); // Replace ["n"] or ["n.m"] = with [n] or [n.m] =
|
||||
luaString = luaString.replace(/\[\]/g, '{}'); // Replace [] with {}
|
||||
luaString = luaString.replace(/\[\n/g, '{\n'); // Replace [ followed by a line break with { followed by a line break
|
||||
luaString = luaString.replace(/]\n/g, '}\n'); // Replace ] followed by a line break with } followed by a line break
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user