Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/bin/bash
n=0; ls -tr | while read i; do n=$((n+1)); mv -- "$i" "$(printf '%03d' "$n").JPG"; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment