alloy lint
UpdatedRuns the lints over the project, or over one file, and nothing else; alloy flux runs them with the compile and the type check. A lint is advice: the code runs, and the lint names a habit that costs bugs. The lints are Flux's, in eight groups:
A lint whose rewrite keeps the program the same carries it, and --fix applies those; in the editor each one is a quick fix, and source.fixAll applies every rewrite of the file.
alloy lint the project of the nearest alloy.toml alloy lint src/game.aly one file alloy lint --fix apply the rewrites that keep the program the same alloy lint -W pedantic a level for this run: -W warns, -A allows, -D denies alloy lint --deny-warnings fail on any hit alloy lint --list every lint with its group and level, in the `[lint.rules]` form
The [lint] table of alloy.toml says where every lint starts, and [lint.rules] sets one. Both modes are on by default, and alloy init writes them:
[lint] recommended = true # the level each lint declares; false starts every lint at allow strict = true # the pedantic group, at warn [lint.rules] correctness = "deny" concat_interpolation = "allow" luau = "allow" naming = "warn" alx.static_conditional_child = "deny" [lint.naming] const = "SCREAMING_SNAKE_CASE" # the case of each kind of name; `alloy doc naming-conventions`
A key is a lint name, a group name, an ingot's <ingot>/<lint>, or alx.<name> for a markup lint; a name beats its group. recommended = false leaves every lint at allow, so the rules table alone says what runs; strict and the table still work on top of it. luau is the group of the type checker's own lints, LocalUnused and the rest, which alloy flux reports.
The old form, deny, warn, and allow lists in [lint] and a [alx.lints] table, still reads for one release and warns with the key that replaces it.
alloy lint --list names every lint in the [lint.rules] form. alloy doc lints lists them; alloy doc <name> explains one, and alloy doc <group> lists a group. The language server shows the same lints as warnings, with the rewrite in the message.
