Skip to content

Instantly share code, notes, and snippets.

@kalkulus
Created May 7, 2013 10:07
Show Gist options
  • Save kalkulus/5531594 to your computer and use it in GitHub Desktop.
Save kalkulus/5531594 to your computer and use it in GitHub Desktop.
BASH: List random file from dir
#!/bin/bash
ls -1 | sort -R | head -n1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment