What is the good way to add file extension ".jpg" to extension-less files with bash?
for f in *.jpg; do mv "$f" "${f%.jpg}"; done for f in *; do mv "$f" "$f.jpg"; done
2.1m questions
2.1m answers
60 comments
57.0k users