RENAME(1) RENAME(1) rename - rename [options] substring replacement file... rename will rename the specified files by replacing the first occurrence of substring in their name by replacement. -s, --symlink . -v, --verbose , . -n, --no-act ; --verbose . -a, --all Replace all occurrences of substring rather than only the first one. -l, --last Replace the last occurrence of substring rather than the first one. -o, --no-overwrite . --symlink , . -i, --interactive . -h, --help . -V, --version . --no-overwrite, --interactive --no-act. , . , /lib. , . If substring is empty, then by default replacement will be added to the start of the filename. With --all, replacement will be inserted in between every two characters of the filename, as well as at the start and end. Normally, only the final path component of a filename is updated. (Or with --symlink, only the final path component of the link.) But if either substring or replacement contains a /, the full path is updated. This can cause a file to be moved between folders. Creating folders, and moving files between filesystems, is not supported. ( ,,tty") , . ,,cbreak" , . ,,cbreak" , : sh -c 'stty -icanon min 1; "$0" "$@"; stty icanon' -i 0 1 2 4 64 foo1, ..., foo9, foo10, ..., foo278, rename foo foo00 foo? rename foo foo0 foo?? foo001, ..., foo009, foo010, ..., foo278. rename .htm .html *.htm . : rename '_with_long_name' '' file_with_long_name.* . mv(1) , ,,https://github.com/util-linux/util-linux/issues[issue tracker]". rename ,,util-linux" . util-linux 2.42.3 2026-09-02 RENAME(1)