1

Is there a possibility to disable multiline_arguments rule only on some of the classes/methods?

I could write

// swiftlint:disable multiline_arguments
someMethod(self, a: a,
b: b c: c)
// swiftlint:enable multiline_arguments

But then I would have to write it in every call and that's exactly what I would like to avoid.

rmaddy
  • 314,917
  • 42
  • 532
  • 579
Jaroslav
  • 1,389
  • 14
  • 27

1 Answers1

0

Depending on how you organized things, you can used nested SwiftLine yml files!

Here's what the docs say:

Nested Configurations

SwiftLint supports nesting configuration files for more granular control over the linting process.

Include additional .swiftlint.yml files where necessary in your directory structure.
Each file will be linted using the configuration file that is in its directory or at the deepest level of its parent directories. Otherwise the root configuration will be used.
included is ignored for nested configurations.
Akash Kundu
  • 1,278
  • 13
  • 21