Horje
bash read multiple lines from user Code Example
bash read multiple lines from user
# Basic syntax:
read -d "~" -p $'Enter your text (type \"~~\" when done):\n' YOUR_TEXT
# Where:
#	- -d tells read to continue reading until the specified delimiter is read.
#		Here I use ~ as the delimiter
#	- -p indicates what to prompt when the script asks for input. I include a
#		message to indicate what to type to stop reading. (I say ~~ because in
#		my shell, I always seem to have to press it twice to stop reading)
#	- YOUR_TEXT is the bash variable that will get the input text 
Source: www.unix.com




Shell

Related
bash read file line by line with spaces Code Example bash read file line by line with spaces Code Example
Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications. Code Example Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications. Code Example
bash load file into list Code Example bash load file into list Code Example
ver espacio en disco linux Code Example ver espacio en disco linux Code Example
linux history with time Code Example linux history with time Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
15