Переход на новую строку bash

echo $'\n'

Либо

echo -e '\n'

Казалось бы всё просто, но из нескольких вариантов сработал только один echo $'\n'

#!/bin/bash echo "n" echo $'\n' echo \n echo '\n'

n n \n

↓ Bash articles ↓
Bash
Bash Scripting
-eq -gt …: Comparison operators
if else: Conditional operators
while loop
date
Arithmetic operations
Pass a file or password over SFTP in a Bash script
Errors Bash

Article author: Andrei Olegovich

Related articles

Search this site

Channel @aofeed Chat @aofeedchat

Contacts and cooperation:
I recommend our hosting beget.com
Write to info@aredel.com if you:
1. Want to write an article for our site or translate an article into your native language.
2. Want to place thematically relevant ads on the site.
3. Ads on my site pass maximum censorship. If you see an ad block unsuitable for school-age children, shocking or misleading - please contact us by e-mail
4. Found a mistake, inaccuracy, bug, etc. on the site. ... .......
5. Articles can be shared on social media by clicking a network icon: