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"
[ Parent
| on HN ]
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....and also
echo 'this is a test\n'
doesn't produce an additional new line because -e wasn't specified.