News for hackers. Stuff that matters.
Re:GNU Nano 4.0 by mruts on Sunday March 24, 2019 @01:15PM (#19477460)
Such an insane default. Currently programming a bittorrent client and was edited files to test some functionality. Was confused for a long time until I realized nano was turning my "echo 'this is a test' > test" into "echo 'this is a test\n' > test"
Re:GNU Nano 4.0 by nemetroid on Sunday March 24, 2019 @02:11PM (#19477764)
Running "echo 'this is a test' > test" produces a file with a newline at the end.
Re:GNU Nano 4.0 by lexicality on Sunday March 24, 2019 @02:05PM (#19477725)
Pretty sure nano was changing your code to

    echo 'this is a test' > test\n
and then echo was adding the newline because you didn't specify -n.
Re:GNU Nano 4.0 by pushpop on Sunday March 24, 2019 @03:06PM (#19478105)
...and also

  echo 'this is a test\n'
doesn't produce an additional new line because -e wasn't specified.
Re:GNU Nano 4.0 by symlinkk on Sunday March 24, 2019 @01:38PM (#19477581)
Funny you mention echo, which prints a newline by default as well.