apply plugin: 'idea'
ideaModule {
    beforeConfigured { module ->
        module.dependencies.clear()
    }
    whenConfigured { module ->
        module.dependencies*.exported = true
    }
}

ideaProject {
    beforeConfigured { project ->
        project.modules.clear()
    }
    withXml { root ->
        root.component.find { it.@name == 'VcsDirectoryMappings' }.mapping.@vcs = 'Git'
    }
}
