Refactor versioning