Batch rename files in bash Add “razvan-” in front of all .txt files in a folder: for f in *.txt; do mv -v "$f" "razvan-${f%}"; done;