Apple User Help

How to change multiple text file names? [closed]

soilbase.0.out.satur.00001.pfb soilbase.0.out.satur.00002.pfb soilbase.0.out.satur.00003.pfb soilbase.0.out.satur.00004.pfb soilbase.0.out.satur.00005.pfb I have files like these and I need to rename like as below, soilbase.1512.out.satur.01513.pfb soilbase.1512.out.satur.01514.pfb soilbase.1512.out.satur.01515.pfb soilbase.1512.out.satur.01516.pfb soilbase.1512.out.satur.01517.pfb I wrote a code to rename, it run but outcome is not exactly what I want. my script is as below function rename() { echo "———————————————— STARTED ————————————————" # Counter. COUNTER=1 # […]