Search code examples
swiftswiftlint

How to run Swiftlint for selected files?


I am looking for the way to run Swiftlint selectively for a single file rather than entire project. How one can run swiftlint so that it can check only one selected files?


Solution

  • Run swiftlint with --path option, like:

    swiftlint --path 'path to your file'