2

I have a text file with a lot of lines like messages:

  1. valid user
  2. operation enable
  3. you don\'t have rights to do this
  4. 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:

  1. you don't have rights to do this

without the "\"

how i can return the exactly line?

1 Answer 1

4

Then try read -r line instead.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.