Screen output is blocked by "| tee" command
I have a script build.py . (It's for creating the ISO file for a special edition of Swift Linux.) This build.py script executes the mintConstructor.py script that I use to modify the Regular Swift Linux ISO to get the special edition Swift Linux ISO. The lines of the script that do this are:
command_remaster = 'python /usr/lib/linuxmint/mintConstructor/mintConstructor.py '
To create Taylor Swift Linux, I enter in a Bash shell the following command:
sudo python /home/username/develop/special/build.py 'ts' 'Taylor Swift Linux'
This allows me to see the full screen output of the mintConstructor.py script that is called by the build.py script. Unfortunately, this command doesn't log the output.
Seeing the mintConstructor.py output on the screen AND logging this output seems to be mutually exclusive. To add insult to injury, the log file is empty UNTIL the entire process is finished.
The command I'm using to try to do both is:
sudo python /home/username/develop/special/build.py 'ts' 'Taylor Swift Linux' | tee /home/username/develop/test-output/test1.txt
How can I get the full mintConstructor.py output on the screen AND log
this output to a file?
|Thread Tools||Search this Thread|
|More UNIX and Linux Forum Topics You Might Find Helpful|
|Thread||Thread Starter||Forum||Replies||Last Post|
|awk command to replace ";" with "|" and ""|" at diferent places in line of file||shis100||Shell Programming and Scripting||7||03-16-2011 08:59 AM|
|"Join" or "Merge" more than 2 files into single output based on common key (column)||Katabatic||Shell Programming and Scripting||1||05-20-2010 11:41 AM|
|Explanation of "total" field in "ls -l" command output||proactiveaditya||UNIX for Dummies Questions & Answers||1||04-18-2010 01:40 AM|
|To record screen output using "script" command||ggayathri||Shell Programming and Scripting||2||03-01-2009 02:54 PM|
|Q: Recording shell script screen output using "script" command ?||lalfonso.gomez||Shell Programming and Scripting||4||01-18-2007 08:31 PM|