Advertisement
kinghitz

filename_case_toggle.sh

Feb 16th, 2019
25
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.15 KB | None | 0 0
  1. #Toggle the case of the file names in the current directory
  2. find . -type f -print0 | xargs -0n 1 bash -c 's=$(dirname "$0")/$(basename "$0");
  3. d=$(dirname "$0")/$(basename "$0"|tr "[A-Z]" "[a-z]"); mv -f "$s" "$d"'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement