2020-12-03 15:55:36 +00:00
|
|
|
# zmv
|
|
|
|
|
|
|
|
> Move or rename files matching a specified extended glob pattern.
|
|
|
|
> See also `zcp` and `zln`.
|
|
|
|
> More information: <http://zsh.sourceforge.net/Doc/Release/User-Contributions.html>.
|
|
|
|
|
2021-05-10 10:03:12 +01:00
|
|
|
- Move files using a regular expression-like pattern:
|
2020-12-03 15:55:36 +00:00
|
|
|
|
|
|
|
`zmv '{{(*).log}}' '{{$1.txt}}'`
|
|
|
|
|
|
|
|
- Preview the result of a move, without making any actual changes:
|
|
|
|
|
|
|
|
`zmv -n '{{(*).log}}' '{{$1.txt}}'`
|
|
|
|
|
|
|
|
- Interactively move files, with a prompt before every change:
|
|
|
|
|
|
|
|
`zmv -i '{{(*).log}}' '{{$1.txt}}'`
|
|
|
|
|
|
|
|
- Verbosely print each action as it's being executed:
|
|
|
|
|
|
|
|
`zmv -v '{{(*).log}}' '{{$1.txt}}'`
|