shell - Recursively strip pattern from filename? -
shell - Recursively strip pattern from filename? -
is there way me utilize find command recursively loop through directory , strip pattern filename?
for example, if have:
styles.css?c=123456 as saved file, able loop through files , match has wildcard *.css?* , turn styles.css?c=123456 styles.css.
try this:
find -type f -name '*.css*' -exec echo 'file="{}"; mv ${file} ${file%\?*} ' \; | bash shell sed
Comments
Post a Comment