this post was submitted on 01 Jul 2025
19 points (100.0% liked)

Programming

21357 readers
305 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS
 

I noticed a repository's .gitattributes entry for *.csv used text eol=crlf so I investigated and found this.

top 7 comments
sorted by: hot top controversial new old
[–] Laser@feddit.org 4 points 1 day ago (1 children)

I think csv is a bad format, if you can even call it that. Yes, there are some cases where it makes sense. I worked with an oscilloscope at uni which output csv. But other than that, I consider it more of a concept than an interface / exchange standard

[–] ulterno@programming.dev 2 points 1 day ago

more of a concept

And it's better to be considered so.
The name itself suggests a Comma as a separator, but we know how inconvenient that is and that tab characters tend to be useful in most cases.
Even LibreOffice Calc asks the user what they expect as the separator when given a csv file, even if it has enough commas to feel correct.

[–] Kissaki@programming.dev 3 points 1 day ago

We want to move down to the next line (line feed) but also to the beginning of that line (carriage return) after all.

[–] verstra@programming.dev 4 points 2 days ago (1 children)

I hate that the pleasant news about standardization of CSV come with the let-down that is using two bytes for new lines.

[–] FizzyOrange@programming.dev 2 points 2 days ago (1 children)

Don't worry, it's not really standardised despite this attempt. You can use UNIX line endings and nothing bad will happen.

[–] Kissaki@programming.dev 8 points 1 day ago (1 children)

Unless you open it in Excel. In which case bad things will happen no matter what you have in the CSV…

[–] ulterno@programming.dev 0 points 1 day ago

If I am using Excel, I am using Windows and I will be changing all text to use CR-LF newline format (if sending from a Linux system) anyway.