stylua
« Back to VersTracker
Description:
Opinionated Lua code formatter
Type: Formula  |  Latest Version: 2.3.1@0  |  Tracked Since: Nov 1, 2025
Links: Homepage  |  formulae.brew.sh
Category: Developer tools
Tags: lua formatter developer-tools code-quality rust
Install: brew install stylua
About:
StyLua is an opinionated code formatter for Lua that enforces a consistent style guide. It parses Lua code into an Abstract Syntax Tree and reprints it according to strict rules, effectively rewriting code to match a standardized format. This eliminates debates over style and ensures codebases remain clean and readable.
Key Features:
  • Opinionated formatting with zero configuration required
  • Supports Lua 5.1, 5.2, 5.3, 5.4, and Luau syntax
  • Fast performance using Rust-based AST manipulation
  • Integration with editors like VS Code and Neovim
Use Cases:
  • Enforcing consistent code style across team projects
  • Automated code formatting in CI/CD pipelines
  • Refactoring legacy Lua codebases to modern standards
Alternatives:
  • lua-fmt – Less maintained; StyLua is more actively developed and supports newer Lua versions
  • EmmyLua formatter – Tied to the EmmyLua plugin; StyLua is a standalone CLI tool
Version History
Detected Version Rev Change Commit
Nov 1, 2025 2:36pm 0 VERSION_BUMP 984ed5f5
Sep 27, 2025 1:03pm 0 VERSION_BUMP d3136e2d
Sep 14, 2025 9:18pm 0 VERSION_BUMP 7c4e847a
Nov 18, 2024 7:30pm 0 VERSION_BUMP 8e4ba9e3