Last active
August 29, 2015 14:15
-
-
Save ariscop/43d8140a642979d6aac0 to your computer and use it in GitHub Desktop.
USDX-WP song hash thingy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import sys | |
from hashlib import md5 | |
from re import split | |
with open(sys.argv[1], "rb") as f: | |
data = b"".join(x for x in split(b"[\r\n]+", f.read()) if not x.startswith(b"#")) | |
m = md5() | |
m.update(data) | |
print(m.hexdigest()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment