This doesn't matter even remotely and it is the height of bike shedding to even have a discussion about it.
Ask HN: Should source files always end in a new line?
21–30 of 40 posts
Re: Ask HN: Should source files always end in a new line?
#22It's having me think about the way prs should be done on divisive topics.
On one hand you have this "guy" who thinks he's gods gift to programming demanding a new line be added to all 30 files you're adding to the project.
On the other hand that "guy" is you.
What then? In both cases.
Re: Ask HN: Should source files always end in a new line?
#23Re: Ask HN: Should source files always end in a new line?
#24I like having the extra line, it is a very minimal difference, but this way it is possible to copy the last line by copying "down" rather than copying "out" to the end of the line.
Re: Ask HN: Should source files always end in a new line?
#25Re: Ask HN: Should source files always end in a new line?
#26Do you mean an empty line? (since, as others have pointed out, every line ends in a newline character, for most text editors). I like having the extra line, it is a very minimal difference, but this way it is possible to copy the last line by copying "down" rather than copying "out" to the end of the line.
> have pointed out, every line ends in a newline character, for most text editors).
My colleagues always add changes that end with that `\ No newline at end of file` diff for certain source files.
Re: Ask HN: Should source files always end in a new line?
#27It shouldn't have to end in a newline, but I still end them all with a newline.
Re: Ask HN: Should source files always end in a new line?
#28Doesn't matter. Pick one. Enforce it with a linter. Move on with your life.
Re: Ask HN: Should source files always end in a new line?
#29OP must've got a PR about this blocking him from merging. It's having me think about the way prs should be done on divisive topics. On one hand you have this "guy" who thinks he's gods gift to programming demanding a new line be added to all 30 files you're adding to the project. On the other hand that "guy" is you. What then? In both cases.