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

Swiftlint fixes & configuration changes; Make GestureManager.delegate weak #134

Merged
merged 15 commits into from
Feb 24, 2021

Conversation

macdrevx
Copy link
Contributor

Pull request checklist:

  • Briefly describe the changes in this PR.
  • Document any changes to public APIs.
  • Apply changelog label ('breaking change', 'bug 🪲', 'build', 'docs', 'feature 🍏', 'performance ⚡', 'testing 💯') or use the label 'skip changelog'
  • Add an entry inside this element for inclusion in the mapbox-maps-ios changelog: <changelog>Breaking: GestureManager.delegate is now weak</changelog>.

Summary of changes

  • Migrated swiftlint config to use opt_in_rules and disabled_rules so that we can more easily discover new rules as they are added.
  • Updated swiftlint excludes for new source layout
  • Autocorrected various lint violations
  • Corrected GestureManager.delegate weak delegate violation
  • Disabled trailing_comma rule since we'd need to wrap closing array braces consistently for it to make sense
  • Added swiftlint:disable commands to ignore other lint warnings
  • Added a child config for the Tests directory that is slightly more permissive.
  • Run swiftlint in CI directly rather than depending on it running as a build phase. This will be helpful as we migrate to SPM-based builds in CI.
  • Run swiftlint in strict mode in CI. This should fail builds that have lint so that we don't regress.

@macdrevx macdrevx added bug 🪲 Something is broken! breaking change ⚠️ If your pull request introduces a breaking change and updates are required when version is published labels Feb 23, 2021
Copy link
Contributor

@julianrex julianrex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sources/MapboxMaps/Style/Generated/Terrain.swift Outdated Show resolved Hide resolved
Copy link
Contributor

@neelmistry94 neelmistry94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One open question, nothing that prevents me from approving

.swiftlint.yml Show resolved Hide resolved
@macdrevx macdrevx enabled auto-merge (squash) February 24, 2021 04:20
@macdrevx macdrevx merged commit 2cf1fc2 into main Feb 24, 2021
@macdrevx macdrevx deleted the ah/lint branch February 24, 2021 04:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change ⚠️ If your pull request introduces a breaking change and updates are required when version is published bug 🪲 Something is broken!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants