« first day (3704 days earlier)      last day (1251 days later) » 

1:50 AM
I think we have to make a "community-wiki" Q-A, simple like this about removing '\r' with dos2unix (or tr). With a few examples into the question. Currently we have a lot of similar Q-As but not a general one, where we can finally target all paste/awk/sed etc Qs where the root cause is the windows line endings.
 
 
9 hours later…
11:10 AM
@thanasisp Someone also made a master list a while back, though people don't look at it, I think. See Meta.
 
11:58 AM
201
Q: What is `^M` and how do I get rid of it?

Christoph WurmWhen I open the file in Vim, I see strange ^M characters. Unfortunately, the world's favorite search engine does not do well with special characters in queries, so I'm asking here: What is this ^M character? How could it have got there? How do I get rid of it?

 
@jesse_b Did you include the link to the reference list?
 
@FaheemMitha That's the list I keep on github, there is also this:
36
Q: Let's compile a list of canonical Q&As

terdonA few of us were talking about this the other day in chat, as we are now quite a bit larger and with several thousand Q&As, there are certain questions that are asked very often. Things like redirecting output, process substitution, batch renaming of files, fixing/reinstalling grub, etc. Let's c...

 
@jesse_b Yes, that's the one I meant. On Meta. @thanasisp ^^
> Active 1 year, 7 months ago
So not very active at all.
 
Not a list that requires much change really
 
@jesse_b Such a list needs to be updated regularly to remain useful and relevant.
IMO, anyway.
The best place to list canonical QAs is not as a mess on meta, but in the tag wiki for the relevant tag(s). — Gilles 'SO- stop being evil' Sep 4 '14 at 13:35
Sounds good in theory, put probably easier said than done.
And I'm not aware of any systematic effort along those lines.
Plus almost nobody would think of looking at the tag wiki for question link, imo.
 
12:14 PM
Yeah it's sometimes very hard to find questions even if you know what you are looking for
I've searched for "why does my shell script choke on whitespace" so many times only to not find the question
 
This list is good but I agree something more direct/easy to maintain is needed. I will read the whole ticket later.
 
The list really doesn't need to change much though, there are one off dupes here and there but for the most part that list covers the bulk of them
That list isn't intended to contain all dupes, just the ones that are frequently asked and that doesn't really change much
 
Exactly, I searched for dos2unix and sed /g and although there are tens of posts with many views and votes, we don't have the simplest one, which says only this thing (they are all mixed with other parameters etc)
 
You could create one but it will be closed with "What is ^M and how do I get rid of it?"
 
This is good target. But the quick solution is in the second answer. I think of using this for closing a couple of ^M posts. But it also says vim I see, that's why the dos2unix is second.
 
12:29 PM
@thanasisp If it's not already there, you could add it to the canonical list.
 
ok, I will see what I could add, I will check the whole post.
 
 
2 hours later…
2:57 PM
@thanasisp go for it! I would urge you to also include things like sed -i 's/\r//g' file (both with and without the -i) though since dos2unix needs to be installed, and silenty changes the original file which can come as a surprise. It also always seemed silly to me to have awhole executable for something as simple as this, but that's just my prejudice.
For some reason I have never used dos2unix.
 
3:21 PM
I think that dos2unix is usually installed by default. Also tr is second, sed third for this. I guess dos2unix is a program checking for more things, so we should recommend it.
For now, I used the ticket jesse_b suggested, and added "look the second answer"
also a good collection of the symptoms in the Q, like with paste, grep, sed how to identify that next line of output overwrites the previous one. I will try to add it as comm wiki Q-A some next day.
 
@thanasisp It isn't on Arch, at least. And I had actually never even heard of it until a couple of years ago or so.
Don't need to make it comm wiki, if you do the work, you should get the credit. CW is mostly deprecated these days anyway.
It's a left over from when it was slightly harder for other users to edit.
Also, this is my own very, very personal opinion. If you prefer dos2unix as the solution, then that's what you should suggest!
 
Arch is targeting more mature users. I guess Ubuntu install it by default ;) for suse also it is.
I can't make it my own post but comm, it is super duplicate.
 
Eh, if you post a general one and a comprehensive, canonical answer, that should be fine. To make it super fine, you can also open a post on meta and explain that you want a canonical answer to a common question.
 

« first day (3704 days earlier)      last day (1251 days later) »