read

BASH builtin for retrieving data from standard input.
More information.
read {variable}
read -a {array}
read -n {character_count} {variable}
read -d {new_delimiter} {variable}
read -r {variable}
read -p "{Enter your input here: }" {variable}
read -s {variable}
while read line; do echo "$line"; done
Copyright © 2014—present the tldr-pages team and contributors.
This work is licensed under the Creative Commons Attribution 4.0 International License (CC-BY).
CC-BY