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

Add a final newline #13

Closed
bajtos opened this issue Jul 24, 2014 · 2 comments · Fixed by #14
Closed

Add a final newline #13

bajtos opened this issue Jul 24, 2014 · 2 comments · Fixed by #14

Comments

@bajtos
Copy link
Contributor

bajtos commented Jul 24, 2014

It is a good practice on most UNIX systems to add a final newline at the end of text files like .json. EOL should be treated as "line terminator", not "line separator". Git diff prints an extra message for files that are missing the last newline character.

I am asking jsonfile to conform to this convention and add a trailing newline to the files produced.

I am happy to submit a patch. Since this change can be considered as controversial, I'd rather wait with my work until there is an agreement that such patch will be accepted.

Related reading:

@jprichardson
Copy link
Owner

Ya, I'm in favor of this. For some reason, I thought that I had done this very recently and was going to respond as such... but sure enough, looking at the code, I haven't. Haha. I'd accept a PR for this. Thanks.

@bajtos bajtos mentioned this issue Jul 25, 2014
@bajtos
Copy link
Contributor Author

bajtos commented Jul 25, 2014

Excellent, submitted a pull request as #14.

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 a pull request may close this issue.

2 participants