Skip to content

Auto format configuration doesn't match classic Arduino IDE #42

Closed
@ubidefeo

Description

@ubidefeo

Describe the bug
The auto format configuration used by the Java IDE represents a de facto Arduino code style that has been established and consistent for years.
The configuration is defined here:
https://github.com/arduino/Arduino/blob/1.8.13/build/shared/lib/formatter.conf
The documentation is here:
http://astyle.sourceforge.net/astyle.html
I personally find it disturbing when running an auto format on a sketch based on an official sketch or documentation snippet results in formatting changes to the existing code and I'm sure this could cause confusion for beginners. My experience indicates that changing the formatting of the official sketches and documentation snippets may be extremely difficult politically.
So I think it's very important to have continuity in the formatting configuration between the two IDE. If we do make changes to the official code style, the change should be based on a conscious decision, rather than just an arbitrary change.
This is the sort of thing that becomes more problematic to change as time goes on.

Desktop (please complete the following information):
OS: Windows 10
Version: 2.0.0-beta.2-snapshot.f9730ab
Date: 2021-02-18T13:01:31.751Z
CLI Version: 0.16.0 alpha [c977a238]

Additional context
https://github.com/arduino/arduino-pro-ide/issues/339
arduino/Arduino#3941

[ originally reported by @per1234 ]

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions