for flashpid in $(pgrep -f flashplayer.so); do
cd "/proc/$flashpid/fd"
for video in $(file * | grep '/tmp/Flash' | sed 's/\(^[0-9]*\).*/\1/g'); do
echo "/proc/$flashpid/fd/$video"
cp "/proc/$flashpid/fd/$video" /mnt/home/vids/$1
done
done
So if I call it savevid, run like savevid videoname.
Doesn't work with dailymotion now, as they changed something to stymie!
I used a slightly different approach by adding a "-c" option to the flash script, where it copies to a designated folder with a date:minute stamp instead of playing it:
## Log only working file in /tmp/flash
while read line; do
var="$(ls -l ${line} 2>/dev/null | grep "Flash")"
if [ ! "$var" ]; then
dl="$( echo ${line} | cut -d/ -f3)"
sed -i "/$dl/d" /tmp/flash
fi
done </tmp/flash
if [ "$1" == "-c" ]; then
nm="$(date +%d-%m-%y:%M)"
cp `cat /tmp/flash` "${DIR}/${nm}.vid"
fi
Earlier, I recommended the FlashVideoReplacer plugin for Firefox but after using it to watch Youtube videos for a while, I found that sometimes it would skip and once in a while there would be problems with the video blacking out. So overall, I think that using playflash gives smoother playback.
FYI, one can alter the script for use with gnome-mplayer as well.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum