Skip to content

Conversation

@paulmedynski
Copy link
Contributor

@paulmedynski paulmedynski commented Jan 30, 2026

Changes to default settings:

  • Changed default indent size from 4 to 2 spaces for all files.
  • Added charset = utf-8 encoding requirement.
  • Added trim_trailing_whitespace = true.
  • Removed redundant file-type-specific indent rules (xml, shell scripts, etc.) since the new defaults cover them.

C# specific:

  • Kept C# files at 4-space indentation (explicitly set).

Windows scripts:

  • Simplified Windows script rule to only specify end_of_line = crlf since other defaults apply.

Removed sections:

  • Removed explicit rules for XML files, shell scripts, and JSON/YAML (now covered by defaults).

Coding style:

New guidelines added:

  • Rule 1: Text files should be UTF-8 encoded, no BOM, with Unix line endings (LF); Windows scripts may use CRLF.
  • Rule 2: Lines should be a maximum of 100 characters (with exceptions for URLs and readability).

Formatting improvements:

  • Reformatted the entire document to wrap lines at ~100 characters for better readability.
  • Changed numbered list from 1. 2. 3. format to 1. 1. 1. (Markdown auto-numbering style).
  • Improved line wrapping for all existing rules to follow the new 100-character guideline

Copilot AI review requested due to automatic review settings January 30, 2026 12:14
@paulmedynski paulmedynski added the Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems. label Jan 30, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates repository-wide formatting defaults and documents new style guidelines (encoding, line endings, and line length) while keeping C# indentation at 4 spaces.

Changes:

  • Update .editorconfig defaults (2-space indent, LF, UTF-8, trim trailing whitespace) with explicit overrides for C# and Windows scripts.
  • Refresh policy/coding-style.md to add new repo-wide text file rules and wrap lines to ~100 chars.
  • Remove redundant file-type-specific .editorconfig sections now covered by the new defaults.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
policy/coding-style.md Adds/rewraps guidelines (UTF-8/LF, 100-char lines) and reformats the rules list.
.editorconfig Changes default formatting settings and simplifies per-file-type overrides (keeps C# at 4 spaces, Windows scripts CRLF).

.editorconfig Outdated
[*.{yml,yaml}]
indent_size = 2
# Use Unix-style line endings.
end_of_line = lf
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think most of our files are already LF, so this seemed to make sense. VSCode won't change an existing file automatically.

Copy link
Contributor

Choose a reason for hiding this comment

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

This one messes with things... Git default behavior at install on Windows is to checkout crlf and check in lf. Changing this at the IDE level will cause a flurry of warnings when commiting, iirc. While I agree, having consistent line ending is a good thing at the repo level, the conflict between IDE (editorconfig) and scm (git) will make a mess of things for Windows users.

For the record, you see that our files are LF already because you're working from linux :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ok I will remove it and let individual devs decide based on their git and IDE config.

cheenamalhotra
cheenamalhotra previously approved these changes Jan 30, 2026
benrr101
benrr101 previously approved these changes Feb 3, 2026
Copy link
Contributor

@benrr101 benrr101 left a comment

Choose a reason for hiding this comment

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

Provisionally approving it...

@paulmedynski paulmedynski dismissed stale reviews from benrr101 and cheenamalhotra via 664a199 February 3, 2026 15:00
@paulmedynski paulmedynski marked this pull request as ready for review February 3, 2026 15:00
@paulmedynski paulmedynski requested a review from a team as a code owner February 3, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants