Skip to content

Instantly share code, notes, and snippets.

@jibaku
Created October 19, 2011 19:22
Show Gist options
  • Save jibaku/1299386 to your computer and use it in GitHub Desktop.
Save jibaku/1299386 to your computer and use it in GitHub Desktop.
Rename files from handbrake
import os
files = os.listdir(os.getcwd())
for f in files:
num = int(f.split('-')[1].split(".")[0])
os.rename(f, "%02i. my series.mp4" % num)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment