Skip to content

Instantly share code, notes, and snippets.

@whoo24
Last active December 27, 2015 08:59
Show Gist options
  • Save whoo24/7300903 to your computer and use it in GitHub Desktop.
Save whoo24/7300903 to your computer and use it in GitHub Desktop.
rename files
import os
import glob
files = glob.glob("C:\\path\\*.exe")
for file in files:
os.rename(file, file.replace(".exe", ".com"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment