Fix: indentation errors: add .editorconfig, health check, docs
This commit is contained in:
committed by
Mathijs Bakker
parent
e1893bc5b7
commit
bc46e06d31
@@ -129,6 +129,29 @@ Optional C# support:
|
||||
- C# LSP server (csharp-ls or OmniSharp)
|
||||
- netcoredbg debugger
|
||||
|
||||
==============================================================================
|
||||
INDENTATION *godotdev-indent*
|
||||
|
||||
Godot (both GDScript and C#) expects **spaces, 4 per indent**.
|
||||
If you use tabs, the LSP often reports this diagnostic:
|
||||
|
||||
Used tab character for indentation instead of space as used before in the file. [-1] [-1]
|
||||
|
||||
To fix this, you should use an `.editorconfig` file. Godot, Neovim
|
||||
(via editorconfig plugins), VSCode, and Rider all respect this.
|
||||
|
||||
Example `.editorconfig`:
|
||||
|
||||
[*.gd]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[*.cs]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
See also: `:checkhealth godotdev`
|
||||
|
||||
==============================================================================
|
||||
License *godotdev-license*
|
||||
|
||||
|
||||
1
doc/tags
1
doc/tags
@@ -2,6 +2,7 @@ godotdev godotdev.txt /*godotdev*
|
||||
godotdev-checkhealth godotdev.txt /*godotdev-checkhealth*
|
||||
godotdev-configuration godotdev.txt /*godotdev-configuration*
|
||||
godotdev-external godotdev.txt /*godotdev-external*
|
||||
godotdev-indent godotdev.txt /*godotdev-indent*
|
||||
godotdev-intro godotdev.txt /*godotdev-intro*
|
||||
godotdev-keymaps godotdev.txt /*godotdev-keymaps*
|
||||
godotdev-license godotdev.txt /*godotdev-license*
|
||||
|
||||
Reference in New Issue
Block a user