Replies: 1 comment
-
You can index with a capture variable and sort it naturally in reverse to achieve what you want: f2 -f 'file(\d+)' -r 'file{$1%02d1}' -sortr natural |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Give a list of files
file01
file02
file03
and a wish to increase the number on each by 1
file02
file03
file04
using
f2 -f "file\d\d" -r "file{2%02d}" -l 1
it fails due to conflicts, it can't rename file01 to file02 because file02 exists
However this would work if file03 was first renamed to file04
Is this possible to do now/add as a feature?
Beta Was this translation helpful? Give feedback.
All reactions