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

style: format iOS code #690

Merged
merged 2 commits into from
Feb 26, 2025
Merged

Conversation

KiwiKilian
Copy link
Collaborator

I formatted the iOS code base using clang-format. It's included with Xcode and available for most other editors. I will add the commit to the .git-blame-ignore-revs directly on main after it's merged.

Bildschirmfoto 2025-02-26 um 18 01 28

@KiwiKilian KiwiKilian requested a review from tyrauber February 26, 2025 17:02
Copy link
Collaborator

@tyrauber tyrauber left a comment

Choose a reason for hiding this comment

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

Can this formatting be enforced by prettier? I think having the formatting come from outside tools with a standard not maintained by the repo is problematic.

@KiwiKilian
Copy link
Collaborator Author

KiwiKilian commented Feb 26, 2025

I tried to find something compatible with Prettier – but there seems to be nothing. So I figured this is better then having the previously completely unknown style? I can see if we can check the style on CI?

clang-format seems to be the defacto standard for Obj-C and should bring it own default style.

@KiwiKilian
Copy link
Collaborator Author

Ah, should we adopt the config from MapLibre Native? https://github.com/maplibre/maplibre-native/blob/main/.clang-format

@tyrauber
Copy link
Collaborator

YES! Good idea!

@KiwiKilian KiwiKilian reopened this Feb 26, 2025
@KiwiKilian KiwiKilian changed the title style: format ios code style: format iOS code Feb 26, 2025
@KiwiKilian
Copy link
Collaborator Author

I've applied the style from MLN. I will add the config file in a separate branch.

@KiwiKilian KiwiKilian merged commit a4ff451 into maplibre:main Feb 26, 2025
13 checks passed
@KiwiKilian KiwiKilian deleted the style/format-ios branch February 27, 2025 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants