Replace all dots in filenames except the extension on Linux 21 一月 2021DevelopmentLinux, Bash, How-To, Clifor f in .; do pre="${f%.}"; suf="${f##.}"; mv -i -f -- "$f" "${pre//./_}.${suf}"; done