peripheryapp / periphery

A tool to identify unused code in Swift projects.
MIT License
5.26k stars 193 forks source link

Initial swiftlint file and fixes #781

Closed mildm8nnered closed 3 months ago

mildm8nnered commented 3 months ago

So this branch has a .swiftlint.yml, and a lot of fixes - I went pretty aggressive here in enabling as much as possible, and also fixing the issues.

There are no really material code changes - many of them were, for example, the "imports weren't sorted", but if you'd prefer a less aggressive approach, let me know.

What there isn't here is any CI or Xcode integration.

mildm8nnered commented 3 months ago

Would love to get general feedback @ileitch if you think this it too aggressive an approach

mildm8nnered commented 3 months ago

Thanks so much for adding this!

That's quite ok. Thanks for picking it up!

I think we can just drop the cyclomatic complexity and body/file length rules and merge as-is. I will go through later and tweak/fix the rules a little.

Shall I make the changes as per your comments, and then you can make any additional ones on top, just so we're not stepping on each others toes? I should be able to get to it tonight or tomorrow at latest ...

ileitch commented 3 months ago

Shall I make the changes as per your comments, and then you can make any additional ones on top, just so we're not stepping on each others toes? I should be able to get to it tonight or tomorrow at latest ...

I think let's just remove the cyclomatic complexity and body/file length rules in this PR, then any other tweaks can be made in follow-up PRs.

mildm8nnered commented 3 months ago

Shall I make the changes as per your comments, and then you can make any additional ones on top, just so we're not stepping on each others toes? I should be able to get to it tonight or tomorrow at latest ...

I think let's just remove the cyclomatic complexity and body/file length rules in this PR, then any other tweaks can be made in follow-up PRs.

Cool - should be good to go!