This is a quick way of renaming a batch of files matching a reg exp in bash.
ls foo*.jpg | awk '{print("mv "$1" "$1)}' | sed 's/foo/bar/2' | /bin/sh
This is a quick way of renaming a batch of files matching a reg exp in bash.
ls foo*.jpg | awk '{print("mv "$1" "$1)}' | sed 's/foo/bar/2' | /bin/sh
Leave a Reply
You must be logged in to post a comment.