You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since compiling with swift by default compiles into the hidden folder ".build" and there are checkouts of swift packages contained in the .build folder, wouldn't it be a good idea, if SwiftLint skips sich a .build folder by default?
We had a case, where an unexperienced user must have called swift build at some point in the - otherwise - Xcode project folder. It contained local swift packages and he wondered, why the build was failing with errors, when others could compile just fine.
It turned out the errors were generated in the .build folders.
Of course we found the issue and it was easily resolved, but it brought up the question to me: Should swiftlint really descend into these folders?
1.) They are most of the times "gitignored" and such can lead to different behaviour on different machines.
2.) There is no point really into descending into those "DerivedData" folders with their checkout Swift Packages, is it?
Therefore I think that rule should be opt-out.
The text was updated successfully, but these errors were encountered:
While .build would be a good candidate to be ignored by default, I'm actually not inclined to hard-code certain folders into SwiftLint and maintain them. Other build tools have other working folders SwiftLint could ignore as well. On the other hand, users might use these folders as part of their projects not knowing (and not caring) that some build tools conventionally use them.
That said, it's very easy to specify explicit includes and excludes in the configuration. That would be the recommended way,
New Issue Checklist
New rule request
Since compiling with swift by default compiles into the hidden folder ".build" and there are checkouts of swift packages contained in the .build folder, wouldn't it be a good idea, if SwiftLint skips sich a .build folder by default?
We had a case, where an unexperienced user must have called
swift build
at some point in the - otherwise - Xcode project folder. It contained local swift packages and he wondered, why the build was failing with errors, when others could compile just fine.It turned out the errors were generated in the .build folders.
Of course we found the issue and it was easily resolved, but it brought up the question to me: Should swiftlint really descend into these folders?
1.) They are most of the times "gitignored" and such can lead to different behaviour on different machines.
2.) There is no point really into descending into those "DerivedData" folders with their checkout Swift Packages, is it?
Therefore I think that rule should be opt-out.
The text was updated successfully, but these errors were encountered: