try this script:
https://gist.github.com/OleksandrKucherenko/9fb14f81a29b46886ccd63b774c5959f