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

[format] Ensure proper ending of the last line #3913

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ricab
Copy link
Collaborator

@ricab ricab commented Jan 31, 2025

Tiny PR to ensure that we end files with a newline. See the POSIX definition of a line.

Copy link

codecov bot commented Jan 31, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.11%. Comparing base (d6855b5) to head (4e03a3d).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3913   +/-   ##
=======================================
  Coverage   89.10%   89.11%           
=======================================
  Files         255      255           
  Lines       14600    14600           
=======================================
+ Hits        13010    13011    +1     
+ Misses       1590     1589    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@andrei-toterman andrei-toterman left a comment

Choose a reason for hiding this comment

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

Yup, tested and it works as expected. Thanks, @ricab!
A question for the future: wouldn't it be nicer if the config options were sorted alphabetically?

@ricab
Copy link
Collaborator Author

ricab commented Jan 31, 2025

It would indeed. I thought about it but resisted the perfectionism here for a change 😅

Addresses review request.
@ricab ricab force-pushed the format-newline-at-eof branch from 5d611cf to e607a6f Compare January 31, 2025 20:10
@ricab
Copy link
Collaborator Author

ricab commented Jan 31, 2025

Not for long...

I think that is it, but I wouldn't mind another set of eyes, as I just pieced it together with sort.

@ricab
Copy link
Collaborator Author

ricab commented Jan 31, 2025

I wonder if we should place Language and Standard first in the section though, with a newline in between.

Move the language and standard keys first in their section of the
`clang-format` configuration, so they can sub/title it.
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