diff --git a/changelog.md b/changelog.md index 0a01507b2d998f1d13b33dccc349130fb230ca43..b1e918cd2afea60a8d9c4dbc29e24e9a344e744f 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,12 @@ # changelog +## 3.6.20 +`2023-5-23` +* `NEW` support connecting by socket with `--socket=PORT` +* `FIX` [#2113] + +[#2113]: https://github.com/LuaLS/lua-language-server/issues/2113 + ## 3.6.19 `2023-4-26` * `FIX` commandline parameter `checklevel` may not work diff --git a/package.json b/package.json index 920598e8abbdb9c8069b457fb4e8e6151e70921d..4e749cd161d94b9ad54e2d462cee11a3dab7424f 100644 --- a/package.json +++ b/package.json @@ -225,9 +225,11 @@ "miss-space-between", "miss-symbol", "missing-global-doc", + "missing-local-export-doc", "missing-parameter", "missing-return", "missing-return-value", + "name-style-check", "need-check-nil", "need-paren", "nesting-long-mark", @@ -994,6 +996,19 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "None", + "description": "%config.diagnostics.missing-local-export-doc%", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "missing-parameter": { "default": "Any", "description": "%config.diagnostics.missing-parameter%", @@ -1033,6 +1048,19 @@ ], "type": "string" }, + "name-style-check": { + "default": "None", + "description": "%config.diagnostics.name-style-check%", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "need-check-nil": { "default": "Opened", "description": "%config.diagnostics.need-check-nil%", @@ -1809,6 +1837,21 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "Warning", + "description": "%config.diagnostics.missing-local-export-doc%", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "missing-parameter": { "default": "Warning", "description": "%config.diagnostics.missing-parameter%", @@ -1854,6 +1897,21 @@ ], "type": "string" }, + "name-style-check": { + "default": "Warning", + "description": "%config.diagnostics.name-style-check%", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "need-check-nil": { "default": "Warning", "description": "%config.diagnostics.need-check-nil%", @@ -2507,6 +2565,22 @@ "scope": "resource", "type": "array" }, + "Lua.nameStyle.config": { + "additionalProperties": false, + "default": {}, + "markdownDescription": "%config.nameStyle.config%", + "patternProperties": { + ".*": { + "type": [ + "string", + "array" + ] + } + }, + "scope": "resource", + "title": "config", + "type": "object" + }, "Lua.runtime.builtin": { "additionalProperties": false, "markdownDescription": "%config.runtime.builtin%", @@ -2601,6 +2675,26 @@ ], "type": "string" }, + "jit.profile": { + "default": "default", + "description": "%config.runtime.builtin.jit.profile%", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, + "jit.util": { + "default": "default", + "description": "%config.runtime.builtin.jit.util%", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, "math": { "default": "default", "description": "%config.runtime.builtin.math%", @@ -3180,5 +3274,5 @@ "sponsor": { "url": "https://github.com/LuaLS/lua-language-server/issues/484" }, - "version": "3.6.19" + "version": "3.6.20" } diff --git a/package.nls.json b/package.nls.json index b17d8bba9e4fc554f569fa2940f2177013d7fe5a..a6e0d0932cba2c71ed533f6d2c5ec9ba040e491e 100644 --- a/package.nls.json +++ b/package.nls.json @@ -44,7 +44,7 @@ "config.diagnostics.circular-doc-class": "Enable diagnostics for two classes inheriting from each other introducing a circular relation.", "config.diagnostics.close-non-object": "Enable diagnostics for attempts to close a variable with a non-object.", "config.diagnostics.code-after-break": "Enable diagnostics for code placed after a break statement in a loop.", - "config.diagnostics.codestyle": "* codestyle-check\n* spell-check", + "config.diagnostics.codestyle": "* codestyle-check\n* name-style-check\n* spell-check", "config.diagnostics.codestyle-check": "Enable diagnostics for incorrectly styled lines.", "config.diagnostics.conventions": "* global-element", "config.diagnostics.count-down-loop": "Enable diagnostics for `for` loops which will never reach their max/limit because the loop is incrementing instead of decrementing.", @@ -79,11 +79,13 @@ "config.diagnostics.libraryFiles.Enable": "Always diagnose these files.", "config.diagnostics.libraryFiles.Opened": "Only when these files are opened will it be diagnosed.", "config.diagnostics.lowercase-global": "Enable lowercase global variable definition diagnostics.", - "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "config.diagnostics.missing-global-doc": "Missing annotations for globals! Global functions must have a comment and annotations for all parameters and return values.", + "config.diagnostics.missing-local-export-doc": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", "config.diagnostics.missing-parameter": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", "config.diagnostics.missing-return": "Enable diagnostics for functions with return annotations which have no return statement.", "config.diagnostics.missing-return-value": "Enable diagnostics for return statements without values although the containing function declares returns.", + "config.diagnostics.name-style-check": "Enable diagnostics for name style.", "config.diagnostics.need-check-nil": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", "config.diagnostics.neededFileStatus": "* Opened: only diagnose opened files\n* Any: diagnose all files\n* None: disable this diagnostic\n\nEnd with `!` means override the group setting `diagnostics.groupFileStatus`.\n", "config.diagnostics.newfield-call": "Enable newfield call diagnostics. It is raised when the parenthesis of a function call appear on the following line when defining a field in a table.", @@ -161,6 +163,7 @@ "config.intelliSense.searchDepth": "Set the search depth for IntelliSense. Increasing this value increases accuracy, but decreases performance. Different workspace have different tolerance for this setting. Please adjust it to the appropriate value.", "config.misc.executablePath": "Specify the executable path in VSCode.", "config.misc.parameters": "[Command line parameters](https://github.com/LuaLS/lua-telemetry-server/tree/master/method) when starting the language server in VSCode.", + "config.nameStyle.config": "Set name style config", "config.runtime.builtin": "Adjust the enabled state of the built-in library. You can disable (or redefine) the non-existent library according to the actual runtime environment.\n\n* `default`: Indicates that the library will be enabled or disabled according to the runtime version\n* `enable`: always enable\n* `disable`: always disable\n", "config.runtime.builtin.basic": "", "config.runtime.builtin.bit": "", @@ -171,6 +174,8 @@ "config.runtime.builtin.ffi": "", "config.runtime.builtin.io": "", "config.runtime.builtin.jit": "", + "config.runtime.builtin.jit.profile": "", + "config.runtime.builtin.jit.util": "", "config.runtime.builtin.math": "", "config.runtime.builtin.os": "", "config.runtime.builtin.package": "", diff --git a/package.nls.pt-br.json b/package.nls.pt-br.json index cbbb5dd938024ed33710fb794211af5170e595f3..f78bf01ac886d4aea76a84b0beda8fc5b9222a06 100644 --- a/package.nls.pt-br.json +++ b/package.nls.pt-br.json @@ -44,7 +44,7 @@ "config.diagnostics.circular-doc-class": "Enable diagnostics for two classes inheriting from each other introducing a circular relation.", "config.diagnostics.close-non-object": "Enable diagnostics for attempts to close a variable with a non-object.", "config.diagnostics.code-after-break": "Enable diagnostics for code placed after a break statement in a loop.", - "config.diagnostics.codestyle": "* codestyle-check\n* spell-check", + "config.diagnostics.codestyle": "* codestyle-check\n* name-style-check\n* spell-check", "config.diagnostics.codestyle-check": "Enable diagnostics for incorrectly styled lines.", "config.diagnostics.conventions": "* global-element", "config.diagnostics.count-down-loop": "Enable diagnostics for `for` loops which will never reach their max/limit because the loop is incrementing instead of decrementing.", @@ -79,11 +79,13 @@ "config.diagnostics.libraryFiles.Enable": "Always diagnose these files.", "config.diagnostics.libraryFiles.Opened": "Only when these files are opened will it be diagnosed.", "config.diagnostics.lowercase-global": "首字母小写的全局变量定义", - "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "config.diagnostics.missing-global-doc": "Missing annotations for globals! Global functions must have a comment and annotations for all parameters and return values.", + "config.diagnostics.missing-local-export-doc": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", "config.diagnostics.missing-parameter": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", "config.diagnostics.missing-return": "Enable diagnostics for functions with return annotations which have no return statement.", "config.diagnostics.missing-return-value": "Enable diagnostics for return statements without values although the containing function declares returns.", + "config.diagnostics.name-style-check": "Enable diagnostics for name style.", "config.diagnostics.need-check-nil": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", "config.diagnostics.neededFileStatus": "* Opened: only diagnose opened files\n* Any: diagnose all files\n* None: disable this diagnostic\n\nEnd with `!` means override the group setting `diagnostics.groupFileStatus`.\n", "config.diagnostics.newfield-call": "在字面量表中,2行代码之间缺少分隔符,在语法上被解析为了一次索引操作", @@ -161,6 +163,7 @@ "config.intelliSense.searchDepth": "Set the search depth for IntelliSense. Increasing this value increases accuracy, but decreases performance. Different workspace have different tolerance for this setting. Please adjust it to the appropriate value.", "config.misc.executablePath": "Specify the executable path in VSCode.", "config.misc.parameters": "[Command line parameters](https://github.com/LuaLS/lua-telemetry-server/tree/master/method) when starting the language service in VSCode.", + "config.nameStyle.config": "Set name style config", "config.runtime.builtin": "Adjust the enabled state of the built-in library. You can disable (or redefine) the non-existent library according to the actual runtime environment.\n\n* `default`: Indicates that the library will be enabled or disabled according to the runtime version\n* `enable`: always enable\n* `disable`: always disable\n", "config.runtime.builtin.basic": "", "config.runtime.builtin.bit": "", @@ -171,6 +174,8 @@ "config.runtime.builtin.ffi": "", "config.runtime.builtin.io": "", "config.runtime.builtin.jit": "", + "config.runtime.builtin.jit.profile": "", + "config.runtime.builtin.jit.util": "", "config.runtime.builtin.math": "", "config.runtime.builtin.os": "", "config.runtime.builtin.package": "", diff --git a/package.nls.zh-cn.json b/package.nls.zh-cn.json index 7f2ce38ad68b59dc76a745c1247e1a10cc144384..2c384a0193253602046ada0f7afa64d4e2732424 100644 --- a/package.nls.zh-cn.json +++ b/package.nls.zh-cn.json @@ -44,7 +44,7 @@ "config.diagnostics.circular-doc-class": "Enable diagnostics for two classes inheriting from each other introducing a circular relation.", "config.diagnostics.close-non-object": "Enable diagnostics for attempts to close a variable with a non-object.", "config.diagnostics.code-after-break": "Enable diagnostics for code placed after a break statement in a loop.", - "config.diagnostics.codestyle": "* codestyle-check\n* spell-check", + "config.diagnostics.codestyle": "* codestyle-check\n* name-style-check\n* spell-check", "config.diagnostics.codestyle-check": "Enable diagnostics for incorrectly styled lines.", "config.diagnostics.conventions": "* global-element", "config.diagnostics.count-down-loop": "Enable diagnostics for `for` loops which will never reach their max/limit because the loop is incrementing instead of decrementing.", @@ -79,11 +79,13 @@ "config.diagnostics.libraryFiles.Enable": "总是诊断这些文件。", "config.diagnostics.libraryFiles.Opened": "只有打开这些文件时才会诊断。", "config.diagnostics.lowercase-global": "首字母小写的全局变量定义", - "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "config.diagnostics.missing-global-doc": "Missing annotations for globals! Global functions must have a comment and annotations for all parameters and return values.", + "config.diagnostics.missing-local-export-doc": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", "config.diagnostics.missing-parameter": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", "config.diagnostics.missing-return": "Enable diagnostics for functions with return annotations which have no return statement.", "config.diagnostics.missing-return-value": "Enable diagnostics for return statements without values although the containing function declares returns.", + "config.diagnostics.name-style-check": "Enable diagnostics for name style.", "config.diagnostics.need-check-nil": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", "config.diagnostics.neededFileStatus": "* Opened: 只诊断打开的文件\n* Any: 诊断任何文件\n* None: 禁用此诊断\n\n以 `!` 结尾的设置优先级高于组设置 `diagnostics.groupFileStatus`。\n", "config.diagnostics.newfield-call": "在字面量表中,2行代码之间缺少分隔符,在语法上被解析为了一次索引操作", @@ -161,6 +163,7 @@ "config.intelliSense.searchDepth": "设置智能感知的搜索深度。增大该值可以增加准确度,但会降低性能。不同的项目对该设置的容忍度差异较大,请自己调整为合适的值。", "config.misc.executablePath": "VSCode中指定可执行文件路径。", "config.misc.parameters": "VSCode中启动语言服务时的[命令行参数](https://github.com/LuaLS/lua-language-server/wiki/Getting-Started#arguments)。", + "config.nameStyle.config": "设定命名风格检查的配置", "config.runtime.builtin": "调整内置库的启用状态,你可以根据实际运行环境禁用掉不存在的库(或重新定义)。\n\n* `default`: 表示库会根据运行版本启用或禁用\n* `enable`: 总是启用\n* `disable`: 总是禁用\n", "config.runtime.builtin.basic": "", "config.runtime.builtin.bit": "", @@ -171,6 +174,8 @@ "config.runtime.builtin.ffi": "", "config.runtime.builtin.io": "", "config.runtime.builtin.jit": "", + "config.runtime.builtin.jit.profile": "", + "config.runtime.builtin.jit.util": "", "config.runtime.builtin.math": "", "config.runtime.builtin.os": "", "config.runtime.builtin.package": "", diff --git a/package.nls.zh-tw.json b/package.nls.zh-tw.json index 6af689b8d86f232a79620430d6ed2a43a9dbfc56..f35fb015ecddd33e5bf7dbbf266ea8302e8de8ba 100644 --- a/package.nls.zh-tw.json +++ b/package.nls.zh-tw.json @@ -44,7 +44,7 @@ "config.diagnostics.circular-doc-class": "Enable diagnostics for two classes inheriting from each other introducing a circular relation.", "config.diagnostics.close-non-object": "Enable diagnostics for attempts to close a variable with a non-object.", "config.diagnostics.code-after-break": "Enable diagnostics for code placed after a break statement in a loop.", - "config.diagnostics.codestyle": "* codestyle-check\n* spell-check", + "config.diagnostics.codestyle": "* codestyle-check\n* name-style-check\n* spell-check", "config.diagnostics.codestyle-check": "Enable diagnostics for incorrectly styled lines.", "config.diagnostics.conventions": "* global-element", "config.diagnostics.count-down-loop": "Enable diagnostics for `for` loops which will never reach their max/limit because the loop is incrementing instead of decrementing.", @@ -79,11 +79,13 @@ "config.diagnostics.libraryFiles.Enable": "總是診斷這些檔案。", "config.diagnostics.libraryFiles.Opened": "只有打開這些檔案時才會診斷。", "config.diagnostics.lowercase-global": "首字母小寫的全域變數定義", - "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "config.diagnostics.luadoc": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "config.diagnostics.missing-global-doc": "Missing annotations for globals! Global functions must have a comment and annotations for all parameters and return values.", + "config.diagnostics.missing-local-export-doc": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", "config.diagnostics.missing-parameter": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", "config.diagnostics.missing-return": "Enable diagnostics for functions with return annotations which have no return statement.", "config.diagnostics.missing-return-value": "Enable diagnostics for return statements without values although the containing function declares returns.", + "config.diagnostics.name-style-check": "Enable diagnostics for name style.", "config.diagnostics.need-check-nil": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", "config.diagnostics.neededFileStatus": "* Opened: 只診斷打開的檔案\n* Any: 診斷所有檔案\n* None: 停用此診斷\n\n以 `!` 結尾的設定優先順序高於組設定 `diagnostics.groupFileStatus`。\n", "config.diagnostics.newfield-call": "在字面常數表中,2行程式碼之間缺少分隔符,在語法上被解析為了一次索引操作", @@ -161,6 +163,7 @@ "config.intelliSense.searchDepth": "設定智慧感知的搜尋深度。增大該值可以增加準確度,但會降低效能。不同的工作區對該設定的容忍度差異較大,請自己調整為合適的值。", "config.misc.executablePath": "Specify the executable path in VSCode.", "config.misc.parameters": "VSCode中啟動語言伺服時的[命令列參數](https://github.com/LuaLS/lua-language-server/wiki/Getting-Started#arguments)。", + "config.nameStyle.config": "Set name style config", "config.runtime.builtin": "調整內建庫的啟用狀態,你可以根據實際執行環境停用(或重新定義)不存在的庫。\n\n* `default`: 表示庫會根據執行版本啟用或停用\n* `enable`: 總是啟用\n* `disable`: 總是停用\n", "config.runtime.builtin.basic": "", "config.runtime.builtin.bit": "", @@ -171,6 +174,8 @@ "config.runtime.builtin.ffi": "", "config.runtime.builtin.io": "", "config.runtime.builtin.jit": "", + "config.runtime.builtin.jit.profile": "", + "config.runtime.builtin.jit.util": "", "config.runtime.builtin.math": "", "config.runtime.builtin.os": "", "config.runtime.builtin.package": "", diff --git a/package/build.lua b/package/build.lua index de4a508e1c634d284d48ae758f51e69dd14d20cf..a65e49659474a56b2f93837df39070e61dc966d4 100644 --- a/package/build.lua +++ b/package/build.lua @@ -1,6 +1,6 @@ local json = require 'json-beautify' -local VERSION = "3.6.19" +local VERSION = "3.6.20" local package = require 'package.package' local fsu = require 'fs-utility' diff --git a/server b/server index 19906a977c517b1e6edfd3ada60e20b2f9179e43..4e2e282eaa79979c0bca2c4d1a2b3c1b2a64544e 160000 --- a/server +++ b/server @@ -1 +1 @@ -Subproject commit 19906a977c517b1e6edfd3ada60e20b2f9179e43 +Subproject commit 4e2e282eaa79979c0bca2c4d1a2b3c1b2a64544e diff --git a/setting/schema-pt-br.json b/setting/schema-pt-br.json index 5d82f03c9f95381fb3ddff2662a995084e86800c..6dcb7a3c9053ce0cbe3f2c31d8abedfcb6bc8c20 100644 --- a/setting/schema-pt-br.json +++ b/setting/schema-pt-br.json @@ -283,9 +283,11 @@ "miss-space-between", "miss-symbol", "missing-global-doc", + "missing-local-export-doc", "missing-parameter", "missing-return", "missing-return-value", + "name-style-check", "need-check-nil", "need-paren", "nesting-long-mark", @@ -389,7 +391,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Any", "Opened", @@ -433,7 +435,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Any", "Opened", @@ -543,7 +545,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Error", "Warning", @@ -591,7 +593,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Error", "Warning", @@ -1052,6 +1054,19 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "None", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "missing-parameter": { "default": "Any", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1091,6 +1106,19 @@ ], "type": "string" }, + "name-style-check": { + "default": "None", + "description": "Enable diagnostics for name style.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "need-check-nil": { "default": "Opened", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -1867,6 +1895,21 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "Warning", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "missing-parameter": { "default": "Warning", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1912,6 +1955,21 @@ ], "type": "string" }, + "name-style-check": { + "default": "Warning", + "description": "Enable diagnostics for name style.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "need-check-nil": { "default": "Warning", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -2648,6 +2706,29 @@ "scope": "resource", "type": "array" }, + "nameStyle": { + "properties": { + "config": { + "$ref": "#/properties/nameStyle.config" + } + } + }, + "nameStyle.config": { + "additionalProperties": false, + "default": {}, + "markdownDescription": "Set name style config", + "patternProperties": { + ".*": { + "type": [ + "string", + "array" + ] + } + }, + "scope": "resource", + "title": "config", + "type": "object" + }, "runtime": { "properties": { "builtin": { @@ -2779,6 +2860,26 @@ ], "type": "string" }, + "jit.profile": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, + "jit.util": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, "math": { "default": "default", "description": "", diff --git a/setting/schema-zh-cn.json b/setting/schema-zh-cn.json index e6707d7aa8f1fd353cbdb943cc7e4c250540b05c..a57991cd78e539e7585ce9a0873067fbf8bc79eb 100644 --- a/setting/schema-zh-cn.json +++ b/setting/schema-zh-cn.json @@ -283,9 +283,11 @@ "miss-space-between", "miss-symbol", "missing-global-doc", + "missing-local-export-doc", "missing-parameter", "missing-return", "missing-return-value", + "name-style-check", "need-check-nil", "need-paren", "nesting-long-mark", @@ -389,7 +391,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Any", "Opened", @@ -433,7 +435,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Any", "Opened", @@ -543,7 +545,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Error", "Warning", @@ -591,7 +593,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Error", "Warning", @@ -1052,6 +1054,19 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "None", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "missing-parameter": { "default": "Any", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1091,6 +1106,19 @@ ], "type": "string" }, + "name-style-check": { + "default": "None", + "description": "Enable diagnostics for name style.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "need-check-nil": { "default": "Opened", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -1867,6 +1895,21 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "Warning", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "missing-parameter": { "default": "Warning", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1912,6 +1955,21 @@ ], "type": "string" }, + "name-style-check": { + "default": "Warning", + "description": "Enable diagnostics for name style.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "need-check-nil": { "default": "Warning", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -2648,6 +2706,29 @@ "scope": "resource", "type": "array" }, + "nameStyle": { + "properties": { + "config": { + "$ref": "#/properties/nameStyle.config" + } + } + }, + "nameStyle.config": { + "additionalProperties": false, + "default": {}, + "markdownDescription": "设定命名风格检查的配置", + "patternProperties": { + ".*": { + "type": [ + "string", + "array" + ] + } + }, + "scope": "resource", + "title": "config", + "type": "object" + }, "runtime": { "properties": { "builtin": { @@ -2779,6 +2860,26 @@ ], "type": "string" }, + "jit.profile": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, + "jit.util": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, "math": { "default": "default", "description": "", diff --git a/setting/schema-zh-tw.json b/setting/schema-zh-tw.json index 26e85f69d94ea104a35713fb805315c41e5946cc..0564ed474b5bb5e29a0ef3b5dd3c751b2b19d322 100644 --- a/setting/schema-zh-tw.json +++ b/setting/schema-zh-tw.json @@ -283,9 +283,11 @@ "miss-space-between", "miss-symbol", "missing-global-doc", + "missing-local-export-doc", "missing-parameter", "missing-return", "missing-return-value", + "name-style-check", "need-check-nil", "need-paren", "nesting-long-mark", @@ -389,7 +391,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Any", "Opened", @@ -433,7 +435,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Any", "Opened", @@ -543,7 +545,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Error", "Warning", @@ -591,7 +593,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Error", "Warning", @@ -1052,6 +1054,19 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "None", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "missing-parameter": { "default": "Any", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1091,6 +1106,19 @@ ], "type": "string" }, + "name-style-check": { + "default": "None", + "description": "Enable diagnostics for name style.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "need-check-nil": { "default": "Opened", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -1867,6 +1895,21 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "Warning", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "missing-parameter": { "default": "Warning", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1912,6 +1955,21 @@ ], "type": "string" }, + "name-style-check": { + "default": "Warning", + "description": "Enable diagnostics for name style.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "need-check-nil": { "default": "Warning", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -2648,6 +2706,29 @@ "scope": "resource", "type": "array" }, + "nameStyle": { + "properties": { + "config": { + "$ref": "#/properties/nameStyle.config" + } + } + }, + "nameStyle.config": { + "additionalProperties": false, + "default": {}, + "markdownDescription": "Set name style config", + "patternProperties": { + ".*": { + "type": [ + "string", + "array" + ] + } + }, + "scope": "resource", + "title": "config", + "type": "object" + }, "runtime": { "properties": { "builtin": { @@ -2779,6 +2860,26 @@ ], "type": "string" }, + "jit.profile": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, + "jit.util": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, "math": { "default": "default", "description": "", diff --git a/setting/schema.json b/setting/schema.json index bd0f95314f1c891fa0869fea5d0b13a1db658ec7..13d97b938d0f2f0bc440cc0b3ffcbb8188535a23 100644 --- a/setting/schema.json +++ b/setting/schema.json @@ -283,9 +283,11 @@ "miss-space-between", "miss-symbol", "missing-global-doc", + "missing-local-export-doc", "missing-parameter", "missing-return", "missing-return-value", + "name-style-check", "need-check-nil", "need-paren", "nesting-long-mark", @@ -389,7 +391,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Any", "Opened", @@ -433,7 +435,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Any", "Opened", @@ -543,7 +545,7 @@ }, "codestyle": { "default": "Fallback", - "description": "* codestyle-check\n* spell-check", + "description": "* codestyle-check\n* name-style-check\n* spell-check", "enum": [ "Error", "Warning", @@ -591,7 +593,7 @@ }, "luadoc": { "default": "Fallback", - "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", + "description": "* circle-doc-class\n* doc-field-no-class\n* duplicate-doc-alias\n* duplicate-doc-field\n* duplicate-doc-param\n* incomplete-signature-doc\n* missing-global-doc\n* missing-local-export-doc\n* undefined-doc-class\n* undefined-doc-name\n* undefined-doc-param\n* unknown-cast-variable\n* unknown-diag-code\n* unknown-operator", "enum": [ "Error", "Warning", @@ -1052,6 +1054,19 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "None", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "missing-parameter": { "default": "Any", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1091,6 +1106,19 @@ ], "type": "string" }, + "name-style-check": { + "default": "None", + "description": "Enable diagnostics for name style.", + "enum": [ + "Any", + "Opened", + "None", + "Any!", + "Opened!", + "None!" + ], + "type": "string" + }, "need-check-nil": { "default": "Opened", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -1867,6 +1895,21 @@ ], "type": "string" }, + "missing-local-export-doc": { + "default": "Warning", + "description": "Missing annotations for exported locals! Exported local functions must have a comment and annotations for all parameters and return values.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "missing-parameter": { "default": "Warning", "description": "Enable diagnostics for function calls where the number of arguments is less than the number of annotated function parameters.", @@ -1912,6 +1955,21 @@ ], "type": "string" }, + "name-style-check": { + "default": "Warning", + "description": "Enable diagnostics for name style.", + "enum": [ + "Error", + "Warning", + "Information", + "Hint", + "Error!", + "Warning!", + "Information!", + "Hint!" + ], + "type": "string" + }, "need-check-nil": { "default": "Warning", "description": "Enable diagnostics for variable usages if `nil` or an optional (potentially `nil`) value was assigned to the variable before.", @@ -2648,6 +2706,29 @@ "scope": "resource", "type": "array" }, + "nameStyle": { + "properties": { + "config": { + "$ref": "#/properties/nameStyle.config" + } + } + }, + "nameStyle.config": { + "additionalProperties": false, + "default": {}, + "markdownDescription": "Set name style config", + "patternProperties": { + ".*": { + "type": [ + "string", + "array" + ] + } + }, + "scope": "resource", + "title": "config", + "type": "object" + }, "runtime": { "properties": { "builtin": { @@ -2779,6 +2860,26 @@ ], "type": "string" }, + "jit.profile": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, + "jit.util": { + "default": "default", + "description": "", + "enum": [ + "default", + "enable", + "disable" + ], + "type": "string" + }, "math": { "default": "default", "description": "",