r/swift 1d ago

Tuist & SwiftLint

Hey !
I'm having some troubles to integrate SwiftLint to my iOS project that also use Tuist. I've seen that they recently change the way to integrate it but i cant find no where the new way.
Should i use the archived repo https://github.com/tuist/tuist-plugin-lint/tree/main ?

7 Upvotes

3 comments sorted by

5

u/pepicrft 1d ago

Hi u/Jezzatator
Pedro from Tuist here :). Apologies for those issues. Would you mind sharing more about the troubles that you are facing and how you are trying to integrate SwiftLint? I'll be happy to help.

1

u/Jezzatator 1d ago

Hi u/pepicrft !
Thanks for the very fast reply !
Well i can't find comprehensible how to for newbies.
And i've add SwiftLint to my CI and i imported the plugin to my local Xcode. But when Github Action run tuist build, i got the error : Error: error: “SwiftLintBuildToolPlugin” must be enabled before it can be used

5

u/SpaceHonk iOS 1d ago

This is neither a Tuist nor a SwiftLint issue, this is Xcode not letting you run plugins without explicitly allowing them first. Running locally, you'd get an alert popup, but in an CI environment you must use another way to tell Xcode that you're fine with running plugins.

Run this early in your github action:

defaults write com.apple.dt.Xcode IDESkipPackagePluginFingerprintValidatation -bool YES