Files
oam/knowledge base/rename.md
2023-07-09 20:48:18 +02:00

724 B

rename

Note: this page refers to the command from the util-linux package on Linux or Homebrew's rename package.

Table of contents

  1. TL;DR
  2. Sources

TL;DR

# Show what would change without changing anything (dry run).
rename -vn foo bar *

rename -n 's/^(\d{4}-\d{2}-\d{2})  (.*)$/$1  addition  $2/' 'file'
rename -n 's/^What.*(\d{4}-\d{2}-\d{2}) at (\d{2}\.\d{2}.\d{2}\..*)/$1 $2/' *

Sources