SwiftLint v0.24.1 Release Notes

  • ๐Ÿ’ฅ Breaking
    • None.
    โœจ Enhancements
    • Invalidate cache when Swift patch version changes.
      Norio Nomura

    • โž• Add private_action opt-in rule which warns against public @IBAction methods.
      Ornithologist Coder #1931

    • โž• Add yoda_condition opt-in rule which warns when Yoda conditions are used. That is, when the constant portion of the expression is on the left side of a conditional statement.
      Daniel Metzing #1924

    • ๐Ÿ”ง Indentation can now be specified via a configuration file.
      Noah McCann RubenSandwich #319

    • Add required_enum_case opt-in rule which allows enums that conform to protocols to require one or more cases. Useful for result enums.
      Donald Ritter

    • Add discouraged_object_literal opt-in rule which encourages initializers over object literals.
      Ornithologist Coder #1987

    • Adds prefixed_toplevel_constant opt-in rule which encourages top-level constants to be prefixed by k.
      Ornithologist Coder #1907

    • โž• Added explicit_acl opt-in rule to enforce explicit access control levels.
      Josep Rodriguez #1822

    ๐Ÿ› Bug Fixes
    • ๐Ÿ›  Fix false positives in control_statement rule when methods with keyword names are used.
      Marcelo Fabri #1946

    • ๐Ÿ›  Fix false positives in for_where rule when pattern matching (if case) is used.
      Marcelo Fabri #1968

    • Fix false positives in unused_closure_parameter rule when closure is wrapped in parentheses.
      JP Simard #1979