-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
file_header rule #1291
Comments
Would you please post (or link) to a copy of your |
Thanks for so quick reply. I configure .swiftlint.yml on terminal. And I want to make some rules generate error messages but not warnings. Some configurations in .swiftlint.yml as follows:
I know file_header rule just generate warning on terminal. Even though I don't configure it with error message, it still does not generate any warning or error? |
I believe that
As an example, see: Lines 24 to 32 in ad10f81
|
Thank you so much. I will have a try. |
Correct, and |
@Jacklchen were you able to fix the issue? |
The rule doesn't seem to work for me. We have very simple copyright header - just one line:
I tried a lot of combinations, for example:
I just wanted the rule to fail, but nothing happens.
and so on ... - no success either I used the I know that the linter works - I can see other rules being reported. The SwiftLint version that I use is |
Actually, my bad. I absolutely missed the fact that this is an opt-in rule. I believe @Jacklchen hasn't added it to Probably it would make it helpful if SwiftLint could display some kind of warning, when a configuration for opt-in rule is present, but the rule itself is "opted-out" (not enabled). To be honest, until today I couldn't clearly understand what did "opt-in rule" actually mean ... |
@mgrebenets I've filled #1350 to track your idea. @Jacklchen I'm closing this since we haven't heard from you in a while. Feel free to reopen if you have more questions related to this issue. |
I don't know why file_header rule has no any effects when the project was compiled in Xcode 8.2. I tried testing it so many times, but it still right all the time. And the filename is "ViewController.swift". But the rule name "Bar.swift" should violate the rule. is it configured or understood wrongly?
The text was updated successfully, but these errors were encountered: