Syntax for renaming files

A swapping-ground for Regular Expression syntax

Syntax for renaming files

Postby Piet200 » Tue May 29, 2018 7:20 am

I have many files which contain the syntax below:

All files contain random text as filename but they all end with the syntax like m01-1 to m01-20 and then m02-01 to m02-15, m03-1 to m03-12

I would like to order them by adding a number in front of it.
It would be fine if the files starting with m01-1 to m01-20 would be numbered for example like
011 to 0120 (followed by the file name)

And the m02 series would be 021 to 0215

As long as the files will be in the correct order when sorting them.

Any suggestion how to do this ?
Piet200
 
Posts: 1
Joined: Tue May 29, 2018 7:02 am

Re: Syntax for renaming files

Postby therube » Tue May 29, 2018 7:43 pm

Some actual examples of the filenames, existing & then renamed?
therube
 
Posts: 1319
Joined: Mon Jan 18, 2016 6:23 pm


Return to Regular Expressions