mirror of
				https://github.com/onceupon/Bash-Oneliner.git
				synced 2025-11-04 07:01:05 +01:00 
			
		
		
		
	Update 'echo -n' example
Putting `echo -n` in backticks isn't a productive example, since command substitution (backticks, or `$()` in Bash) already removes the trailing newline(s). References: * <https://www.gnu.org/software/bash/manual/html_node/Command-Substitution.html> * <http://heirloom.sourceforge.net/sh/sh.1.html#4>
This commit is contained in:
		@@ -2590,7 +2590,9 @@ printf 'hello world\n%.0s' {1..5}
 | 
				
			|||||||
```
 | 
					```
 | 
				
			||||||
##### Do not echo the trailing newline
 | 
					##### Do not echo the trailing newline
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
username=`echo -n "bashoneliner"`
 | 
					echo -n "Doing the things... "
 | 
				
			||||||
 | 
					# (do things)
 | 
				
			||||||
 | 
					echo "done."
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
##### Copy a file to multiple files (e.g copy fileA to file(B-D))
 | 
					##### Copy a file to multiple files (e.g copy fileA to file(B-D))
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user