Skip to content
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

Add ability to run swiftlint in strict mode #195

Merged
merged 2 commits into from Feb 16, 2019

Conversation

Projects
None yet
4 participants
@FabioTacke
Copy link
Contributor

FabioTacke commented Feb 15, 2019

Introduce a strict mode that treats warnings like errors in inline mode, i.e. fails the build when a warning occurrs.

@DangerCI

This comment has been minimized.

Copy link

DangerCI commented Feb 15, 2019

Warnings
⚠️

Any changes to library code should be reflected in the Changelog.

Please consider adding a note there and adhere to the Changelog Guidelines.

⚠️

Sources/Danger-Swift/Fake.swift#L1 - Files should have a single trailing newline. (trailing_newline)

⚠️

Sources/Danger/Plugins/SwiftLint/SwiftLint.swift#L34 - Function should have complexity 10 or less: currently complexity equals 11 (cyclomatic_complexity)

Generated by 🚫 Danger Swift against dfc83d3

@f-meloni
Copy link
Member

f-meloni left a comment

Looks good, just a small comment

violation.update(file: updatedPath)
violation.file = updatedPath
if strict {
violation.severity = .error

This comment has been minimized.

@f-meloni

f-meloni Feb 15, 2019

Member

can you please add a specific test for this? This would (I think), also change how the violation gets displayed on the markdown table, in that case that should be tested as well 👍

@f-meloni
Copy link
Member

f-meloni left a comment

Ace! 💯

@f-meloni f-meloni merged commit c9b8625 into danger:master Feb 16, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@peril-staging

This comment has been minimized.

Copy link
Contributor

peril-staging bot commented Feb 24, 2019

Thanks for the PR @FabioTacke.

This PR has been shipped in v1.4.0 - CHANGELOG.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
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.