Open ab22593k opened 1 year ago
@CppCXY
because of my bad option name, you may have misunderstood. remove empty lines of a statement requires a set of options
keep_line_after_if_statement = maxLine:1
keep_line_after_do_statement = maxLine:1
keep_line_after_while_statement = maxLine:1
keep_line_after_repeat_statement = maxLine:1
keep_line_after_for_statement = maxLine:1
keep_line_after_local_or_assign_statement = maxLine:1
keep_line_after_function_define_statement = keepLine:1
keep_line_after_expression_statement = maxLine:1
By the way, can it supports keep_line_after_* = maxLine:1
?
good idea, after refactor, I will try
How are you using the lua-language-server?
Visual Studio Code Extension (sumneko.lua)
Which OS are you using?
Linux
What is the issue affecting?
Formatting
Expected Behaviour
continuous empty lines should be removed
Actual Behaviour
nothing happen?
Reproduction steps
Format
the codeAdditional Notes
I have the following vscode setting.json file:
Log File
[21:31:44.449][info] [#0:/home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/main.lua:65]: Lua Lsp startup, root: /home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server [21:31:44.450][info] [#0:/home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/main.lua:66]: ROOT: /home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server [21:31:44.450][info] [#0:/home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/main.lua:67]: LOGPATH: /home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/log [21:31:44.450][info] [#0:/home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/main.lua:68]: METAPATH: /home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/meta [21:31:44.450][info] [#0:/home/wahabz/.vscode/extensions/sumneko.lua-3.6.2-linux-x64/server/main.lua:69]: VERSION: 3.6.2 [21:31:44.520][info] [#0:script/service/service.lua:141]: ========= Medical Examination Report ========= --------------- Memory --------------- Total: 1.545 MB
00 : 1.545 MB
01 : 0.000 MB
02 : 0.000 MB
03 : 0.000 MB
04 : 0.000 MB
--------------- Coroutine --------------- Total: 0 Running: 0 Suspended: 0 Normal: 0 Dead: 0 --------------- Cache --------------- Total: 1 Dead: 0 --------------- RPC --------------- Holdon: 0 Waiting: 0
[21:31:44.531][info] [#0:script/language.lua:137]: VSC language: en-us [21:31:44.531][info] [#0:script/language.lua:138]: LS language: en-us