Timeline for How read file paths mentioned in a text file inside a Korn shell script?
Current License: CC BY-SA 4.0
11 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jul 5, 2021 at 18:59 | answer | added | Vandit Goel | timeline score: 0 | |
| Jul 5, 2021 at 18:56 | comment | added | Vandit Goel | I used dos2unix to convert the file, and it worked. | |
| Jul 5, 2021 at 18:34 | comment | added | Vandit Goel | I've edited my answer to include the complete output of the script. | |
| Jul 5, 2021 at 18:29 | history | edited | Vandit Goel | CC BY-SA 4.0 | Added complete output instead of just the error. |
| Jul 5, 2021 at 18:11 | comment | added | Vandit Goel | The script runs fine if I hard code the filename in egrep command. I get the desired output in the out_file. | |
| Jul 5, 2021 at 18:08 | comment | added | Vandit Goel | Yes the error message is prefixed by a single dot. The file that I am reading from has been edited in windows before transferring to UNIX server. The cd succeeds (I did pwd to check). | |
| Jul 5, 2021 at 16:44 | comment | added | Kusalananda♦ | Is the error message prefixed by a single dot, as you have shown? Has the file that you are reading from been edited on a Windows system previous to having been transferred to your AIX system? Does the cd in the script actually succeed? What is the full output of the script when you encounter the error? | |
| Jul 5, 2021 at 16:02 | comment | added | Vandit Goel | In the script I cd to log_dir which is where these log files are present. | |
| Jul 5, 2021 at 15:46 | comment | added | Kusalananda♦ | Note that you seem to assume that code_a.log and code_b.log are available in the script's current directory. If that is not the case, then either update the text file with the full absolute path of the files, or cd in the scirpt to the correct directory before reading from the file. | |
| Jul 5, 2021 at 15:42 | review | First posts | |||
| Jul 5, 2021 at 20:36 | |||||
| Jul 5, 2021 at 15:42 | history | asked | Vandit Goel | CC BY-SA 4.0 |