I copied something from Windows to Nano in WSL and it included carriage returns (CR characters). Even though I removed all carriage returns with the text editor (Notepad++) these are still added after copying, possibly by Windows itself - The more the window is narrower, the more carriage returns Windows adds.
How could I remove all carriage returns in a find and replace (
CTRL+\) action in Nano?
If I paste the script and just saving (CTRL+O) there is no change (I made sure that when saving, dos mode is toggled off).
dos2unix on the file didn't help - it still contains these Green boxes and as for now I can remove them only manually (not a solution of course). I know there are carriage returns, because if I copy the file back to Notepad++, I see these are displayed as CR chars, when I do
View > Show symbol > Show all characters.