Python flexible slugify function.
