Quote:
Originally Posted by weezy99
1. Windows text file contains a double backslash (\\) and the \\ is being written back as a single \ which corrupts the file.
|
In UNIX the backslash is one of the escape chars so if you need one as literal backslash you have to escape it:
Code:
~]$ echo "\\\\"
\\
~]$ echo "\\\\\\"
\\\
Quote:
Originally Posted by weezy99
2. I am not getting the last line of text in the file written back out.
|
Might be a line ending issue?
Quote:
Originally Posted by weezy99
3. Some lines of text are not written back out completely.
|
Running your script with the appropriate verbose, trace and or debug switches for your shell will help you understand how lines are executed.