6903 shaares
Print the duration of each video passed as argument
#!/bin/bash
for video in "$@"
do
duration=$(mediainfo "$video" |grep "Duration" |head -n 1 |cut -d':' -f 2)
echo "$duration ― $video"
done
Need the mediainfo
command (install with apt)