Crates.io | ren3 |
lib.rs | ren3 |
version | 0.1.0 |
source | src |
created_at | 2019-01-03 03:26:09.794005 |
updated_at | 2019-01-03 03:26:09.794005 |
description | Do file renaming using regular expressions. |
homepage | |
repository | https://github.com/Aloxaf/ren3 |
max_upload_size | |
id | 105156 |
size | 13,899 |
Do file renaming using regular expressions.
Inspired by ren2
cargo install ren3
USAGE:
ren3 [FLAGS] <expression> [dir]...
FLAGS:
-b, --brief only display base name
-D, --directory-only only rename directories
-F, --file-only only rename files
-f, --force apply changes
-h, --help Prints help information
-r, --recursive rename subdirectories recursively
-V, --version Prints version information
ARGS:
<expression> sed-like expression
<dir>... directories to rename
> ls
foo-1.jpg foo2.jpg
> ren3 's/.*(\d+\.jpg)/bar-$1' -f
[OK] ./foo2.jpg -> ./bar-2.jpg
[OK] ./foo-1.jpg -> ./bar-1.jpg
> ls
bar-1.jpg bar-2.jpg