opensearch-project / security

🔐 Secure your cluster with TLS, numerous authentication backends, data masking, audit logging as well as role-based access control on indices, documents, and fields
https://opensearch.org/docs/latest/security-plugin/index/
Apache License 2.0
191 stars 272 forks source link

add .editorconfig #1547

Open rursprung opened 2 years ago

rursprung commented 2 years ago

Is your feature request related to a problem? Please describe. due to the lack of an .editorconfig PRs are not properly aligned in terms of formatting, etc.

Describe the solution you'd like add a .editorconfig with generally agreed upon defaults. note that the main OpenSearch repo contains a .editorconfig which would be a good starting point.

Describe alternatives you've considered using .editorconfig is the de-facto standard.

Additional context i didn't check the status of the other OpenSearch repos. if it's missing in them as well this might be well suited for a meta-issue which is then applied to all of them (so that all have the same .editorconfig.

side-note: adding a .gitattributes in the same step might be a good idea. again, this file is present in the main OpenSearch repo but missing here.

davidlago commented 1 year ago

Sorry for the late reply. We use checkstyle for linting, and we've documented how to run locally prior to submitting PRs here

rursprung commented 1 year ago

@davidlago: one tool doesn't exclude the other: checkstyle is used to check the style, editorconfig is used to configure the editor. the latter allows formatting the code automatically in the correct way expected by the former. the two tools are complimentary. please re-consider (not just for the security plugin, in general for all OpenSearch repos).

davidlago commented 1 year ago

Gotcha... let me re-open, perhaps we should move this to the org level as a broader question/recommendation that perhaps we can make there.