Stop process while running script
Hi everyone,
I am trying to get some information out of mplayer. I want to know the length of a video file. I used "-identify" switch it returns a whole bunch of information including something called "ID_LENGTH" which is exactly what I need. Here is what I do in the bash script. (I pass the name of the video file as an argument to the script) Code:
mplayer -identify "$1" 2> /dev/null | grep "ID_LENGTH" > /tmp/out.$$ Thanx in advance |
You could run the mplayer process in the background and then use "kill -SIGQUIT %1" to kill it.
Code:
mplayer -identify "$1" 2> /dev/null | grep "ID_LENGTH" > /tmp/out.$$ & |
All times are GMT -5. The time now is 08:05 AM. |