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
1. Create an addon config at `addon/library/config.json` where `"Lua.runtime.nonstandardSymbol"` has an array with `>1` entries.
2. Enable addon in new workspace.
3. 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