70 lines
2.3 KiB
Text
70 lines
2.3 KiB
Text
# lilith-gdtoolkit-config: GDScript Linting Configuration
|
|
# Sync to project: lilith-gdtoolkit-sync
|
|
# Check for drift: lilith-gdtoolkit-sync --check
|
|
|
|
class-definitions-order:
|
|
- tools
|
|
- classnames
|
|
- extends
|
|
- docstrings
|
|
- signals
|
|
- enums
|
|
- consts
|
|
- staticvars
|
|
- exports
|
|
- pubvars
|
|
- prvvars
|
|
- onreadypubvars
|
|
- onreadyprvvars
|
|
- others
|
|
|
|
# Naming conventions (GDScript standard)
|
|
class-name: ([A-Z][a-z0-9]*)+
|
|
class-variable-name: _?[a-z][a-z0-9]*(_[a-z0-9]+)*
|
|
class-load-variable-name: (([A-Z][a-z0-9]*)+|_?[a-z][a-z0-9]*(_[a-z0-9]+)*)
|
|
constant-name: _?[A-Z][A-Z0-9]*(_[A-Z0-9]+)*
|
|
enum-name: ([A-Z][a-z0-9]*)+
|
|
enum-element-name: '[A-Z][A-Z0-9]*(_[A-Z0-9]+)*'
|
|
function-name: (_on_([A-Z][a-z0-9]*)+(_[a-z0-9]+)*|_?[a-z][a-z0-9]*(_[a-z0-9]+)*)
|
|
function-argument-name: _?[a-z][a-z0-9]*(_[a-z0-9]+)*
|
|
function-preload-variable-name: ([A-Z][a-z0-9]*)+
|
|
function-variable-name: '[a-z][a-z0-9]*(_[a-z0-9]+)*'
|
|
load-constant-name: (([A-Z][a-z0-9]*)+|_?[A-Z][A-Z0-9]*(_[A-Z0-9]+)*)
|
|
loop-variable-name: _?[a-z][a-z0-9]*(_[a-z0-9]+)*
|
|
signal-name: '[a-z][a-z0-9]*(_[a-z0-9]+)*'
|
|
sub-class-name: _?([A-Z][a-z0-9]*)+
|
|
|
|
# Limits (aligned with Lilith ecosystem standards)
|
|
max-line-length: 100
|
|
max-file-lines: 500
|
|
# Project-specific carveout: GDExtension wrapper classes and autoload singletons
|
|
# legitimately expose wide APIs and cannot be meaningfully split.
|
|
# DataLoader — game data bus, 99 typed accessors (all intentional)
|
|
# city.gd — GdCity GDExtension bridge, ~48 bridge methods
|
|
# game_state / ecology_db / data_loader_ecology — wide singletons by design
|
|
# Game-logic classes are expected to stay well under 30.
|
|
max-public-methods: 100
|
|
max-returns: 6
|
|
function-arguments-number: 10
|
|
|
|
# Indentation: tabs (GDScript convention)
|
|
tab-characters: 1
|
|
|
|
# Enabled checks
|
|
# trailing-whitespace, unnecessary-pass, mixed-tabs-and-spaces are active (not null)
|
|
|
|
# Disabled checks (set per-rule to null = no custom pattern, rule still active)
|
|
comparison-with-itself: null
|
|
duplicated-load: null
|
|
expression-not-assigned: null
|
|
no-elif-return: null
|
|
|
|
# Exclusions
|
|
# Project-specific: no-else-return fights explicit early-return readability in
|
|
# physics code, and unused-argument fires on GDExtension wrapper methods that
|
|
# intentionally accept args for parity with the Rust side.
|
|
disable:
|
|
- no-else-return
|
|
- unused-argument
|
|
excluded_directories: !!set
|
|
.git: null
|