LuaLS / LuaLS/lua-language-server
`Lua.runtime.nonstandardSymbol` value not being properly copied from addon `config.json` to workspace `.vscode/settings.json`.
还没有人认领这个 Issue。
- 主要语言
- Lua
- 星标
- 4.4k
- 派生
- 442
- PR 合并指标
- 30 天内没有已合并 PR
描述
How are you using the lua-language-server?
Visual Studio Code Extension (sumneko.lua)
Which OS are you using?
Windows
What is the issue affecting?
Libraries
Expected Behaviour
Lua.runtime.nonstandardSymbol from addon's config.json should be correctly copied to .vscode/settings.json.
Actual Behaviour
Only the LAST element of the addon's Lua.runtime.nonstandardSymbol array is being copied to .vscode/settings.json Lua.runtime.nonstandardSymbol array.
Example:
Input addon/library/config.json:
{
"name": "BWLua",
"words": ["--bwlua"],
"settings": {
"Lua.runtime.version": "Lua 5.1",
"Lua.runtime.special": {},
"Lua.runtime.builtin": {
"os": "disable",
"package": "disable",
"io": "disable",
"utf8": "disable",
"jit": "disable",
"debug": "disable",
"coroutine": "disable"
},
"Lua.runtime.nonstandardSymbol": ["`", "+=", "-=", "*=", "/=", "^=", "continue"]
}
}
Output .vscode/settings.json
{
"Lua.runtime.nonstandardSymbol": [
"continue"
],
"Lua.runtime.builtin": {
"io": "disable",
"utf8": "disable",
"debug": "disable",
"coroutine": "disable",
"package": "disable",
"os": "disable",
"jit": "disable"
},
"Lua.runtime.version": "Lua 5.1",
"Lua.workspace.library": [
".../LuaAddons/bwlua-language-addon/library"
]
}
Expected "Lua.runtime.nonstandardSymbol" value is: ["`", "+=", "-=", "*=", "/=", "^=", "continue"]
Reproduction steps
- Create an addon config at
addon/library/config.jsonwhere"Lua.runtime.nonstandardSymbol"has an array with>1entries. - Enable addon in new workspace.
- Observe
.vscode/settings.json.
Additional Notes
No response
Log File
No response
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先重现 addon/library/config.json 的输入,并将其与生成的 .vscode/settings.json 进行比较。跟踪 Lua.runtime.nonstandardSymbol 的 addon 设置传递,然后验证数组中的所有条目都保留在工作区设置输出中。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- lua, vscode
- 领域
- tooling
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100