Python+regex to clean filenames
Budget: ₹600 – ₹1,500 INR
Write a Python script that goes through all files within a folder and cleans the filenames with a regex.
Pattern:
We are removing tempo and key information:
Tempo: 100 - 200 within that range
Key: A digit followed by A or B. 1A, 6B, 8A, etc...
The regex should remove from the filenames things like
- 140
- 3A
Examples:
132 - 6A - Stand By - Oscar L Warehouse Remix.mp3
Ethereal - 7A - 124.mp3
150 - 12A - Do You 150?.mp3
147 - 9A - xxxIV.mp3
To become:
Stand By - Oscar L Warehouse Remix.mp3
Ethereal.mp3
Do You 150?.mp3
xxxIV.mp3
Pattern:
We are removing tempo and key information:
Tempo: 100 - 200 within that range
Key: A digit followed by A or B. 1A, 6B, 8A, etc...
The regex should remove from the filenames things like
- 140
- 3A
Examples:
132 - 6A - Stand By - Oscar L Warehouse Remix.mp3
Ethereal - 7A - 124.mp3
150 - 12A - Do You 150?.mp3
147 - 9A - xxxIV.mp3
To become:
Stand By - Oscar L Warehouse Remix.mp3
Ethereal.mp3
Do You 150?.mp3
xxxIV.mp3