Sample Header Ad - 728x90

Redirect command output to file (append) and then append a newline character

0 votes
1 answer
331 views
I'm running the following one-liner: cat input.txt | xargs -I{} bash -c './script.sh "{}"' >> output.txt The script works and does exactly what I want it to do. The only issue is that the output is appended in the file all in a single "line". How can I modify this so that a new line character is also appended after each line is processed?
Asked by dlyk1988 (103 rep)
May 10, 2024, 12:27 PM
Last activity: May 10, 2024, 01:30 PM