I have a text file with a lot of lines like messages:
- valid user
- operation enable
- you don\\'t have rights to do this
- please enter more than 5 characters ...
and i use a bash script to read this file like
while read line
do
....
echo "${line}"
....
done
and returns all good, but in the message 3, just return:
- you don't have rights to do this
without the "\\"
how i can return the exactly line?
然后尝试read -r line
。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.