I am using the following command to open a terminal and execute an script. How to save the output to a log file.
gnome-terminal -x bash -c "print1.py; read -n1" &
I tried following options but didn't succeed. Kindly suggest a solution.
gnome-terminal -x bash -c "print1.py; read -n1" & > log.txt
gnome-terminal -x bash -c "print1.py; read -n1" & | tee log.txt
gnome-terminal -x bash -c "print1.py; read -n1" & | tee -a log.txt
No comments:
Post a Comment