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 .editorconfig file #14271

Merged
merged 1 commit into from
Mar 2, 2021

Conversation

ladislas
Copy link
Contributor

Summary of changes

Following comment #14199 (comment), this PR adds and .editorconfig file. From https://editorconfig.org/

What is EditorConfig?

EditorConfig helps maintain consistent coding styles for multiple developers working on the same project across various editors and IDEs. The EditorConfig project consists of a file format for defining coding styles and a collection of text editor plugins that enable editors to read the file format and adhere to defined styles. EditorConfig files are easily readable and they work nicely with version control systems.

Impact of changes

No impact. Contributor can simply install the plugin in their favorite editor (https://editorconfig.org/#download) and formatting will happen automatically.

Codeclimate can also check for EditorConfig compliance, useful for PRs. https://docs.codeclimate.com/docs/editorconfig

Migration actions required

none

Documentation

Maybe ask people to install the plugin?


Pull request type

[x] Patch update (Bug fix / Target update / Docs update / Test update / Refactor)
[] Feature update (New feature / Functionality change / New API)
[] Major update (Breaking change E.g. Return code change / API behaviour change)

Test results

[x] No Tests required for this change (E.g docs only update)
[] Covered by existing mbed-os tests (Greentea or Unittest)
[] Tests / results supplied as part of this PR

Reviewers

@0xc0170 @hugueskamba


@ciarmcom ciarmcom added the release-type: patch Indentifies a PR as containing just a patch label Feb 11, 2021
@ciarmcom
Copy link
Member

@ladislas, thank you for your changes.
@0xc0170 @hugueskamba @ARMmbed/mbed-os-maintainers please review.

@ciarmcom ciarmcom requested review from 0xc0170, hugueskamba and a team February 11, 2021 21:30
@ciarmcom ciarmcom added needs: review stale Stale Pull Request labels Feb 11, 2021
@ciarmcom
Copy link
Member

This pull request has automatically been marked as stale because it has had no recent activity. @0xc0170, @hugueskamba, @ARMmbed/mbed-os-maintainers, please complete review of the changes to move the PR forward. Thank you for your contributions.

@0xc0170
Copy link
Contributor

0xc0170 commented Feb 22, 2021

@ladislas What's your experience with this along with our coding style (using astyle formatter) ?
I am afraid of maintaining another config. The intention here is to configure your editor in generic way (not covering everything just basics to avoid the most common mistakes as trailing spaces or misalignment) ?

@ladislas
Copy link
Contributor Author

The intention here is to configure your editor in generic way (not covering everything just basics to avoid the most common mistakes as trailing spaces or misalignment) ?

@0xc0170 yes absolutely. Just to make sure you don't forget to trim trailing whitespaces, add an empty line at the end of a file, set the correct indentation (tab vs space, 2/4/8 length), etc.

We don't use astyle in our project, we use clang-format, and we had absolutely no issues. editorconfig is really generic and will not interfere in formatting for example.

0xc0170
0xc0170 previously approved these changes Feb 22, 2021
@mergify mergify bot added needs: CI and removed needs: review labels Feb 22, 2021
@ciarmcom ciarmcom removed the stale Stale Pull Request label Feb 22, 2021
@ciarmcom
Copy link
Member

This pull request has automatically been marked as stale because it has had no recent activity. @ARMmbed/mbed-os-maintainers, please start CI to get the PR merged.

@ciarmcom ciarmcom added the stale Stale Pull Request label Feb 24, 2021
@0xc0170
Copy link
Contributor

0xc0170 commented Feb 25, 2021

CI started

@mbed-ci
Copy link

mbed-ci commented Feb 25, 2021

Jenkins CI Test : ✔️ SUCCESS

Build Number: 1 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️

@0xc0170 0xc0170 added needs: review and removed ready for merge stale Stale Pull Request labels Feb 25, 2021
@0xc0170
Copy link
Contributor

0xc0170 commented Feb 25, 2021

@adbridge @harmut01 Please review

.editorconfig Outdated Show resolved Hide resolved
@ladislas ladislas force-pushed the ladislas/feature/add-editorconfig branch from 92c3167 to 2e53109 Compare February 25, 2021 15:26
@ladislas ladislas force-pushed the ladislas/feature/add-editorconfig branch from 2e53109 to b23a8eb Compare February 25, 2021 15:26
@mergify mergify bot dismissed 0xc0170’s stale review February 25, 2021 15:27

Pull request has been modified.

@mergify mergify bot added needs: CI and removed needs: review labels Feb 25, 2021
@ciarmcom ciarmcom added the stale Stale Pull Request label Feb 27, 2021
@0xc0170
Copy link
Contributor

0xc0170 commented Mar 1, 2021

CI restarted

@mbed-ci
Copy link

mbed-ci commented Mar 1, 2021

Jenkins CI Test : ✔️ SUCCESS

Build Number: 2 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️

@mbed-ci
Copy link

mbed-ci commented Mar 1, 2021

Jenkins CI Test : ✔️ SUCCESS

Build Number: 3 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️

@0xc0170 0xc0170 merged commit 03b9d5a into ARMmbed:master Mar 2, 2021
@mergify mergify bot removed the ready for merge label Mar 2, 2021
@mbedmain mbedmain added release-version: 6.9.0 Release-pending and removed release-type: patch Indentifies a PR as containing just a patch Release-pending labels Mar 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants