Solving it the unix way:
ls -1 | sort -R | sxiv -f -s f -S 5 -
So it's ls -1
to list the content of current directory (presumably where your pictures are), with one file per line, so we can then pipe it to sort
, with the -R
option to sort randomly, then piping the result to sxiv
, a lightweight image viewer available on most distro (I just checked, it's available on Debian). For its options : -f
means it's fullscreen, -s f
makes it scale to fit the image on screen as well as possible, -S 5
tells it to start in slideshow mode and change picture every 5 seconds, and -
is to tell it to take the files list from stdin (thus from the ls
and sort
commands).
This won't work for videos, though, only pictures.