apply plugin: 'headlessmc-modules'

dependencies {
    jarLibsApi project(':headlessmc-api')
    jarLibsApi project(':headlessmc-logging')

    jarLibs group: 'dev.xdark', name: 'deencapsulation', version: '1.0'
    jarLibs project(':headlessmc-jline')
}

module {
    name = 'headlessmc.runtime'
    access = ACC_OPEN

    // I do not think we actually need to export anything
    // Rather, we just cannot export jline or com/sun packages
    exports 'io/github/headlesshq/headlessmc/api'
    exports 'io/github/headlesshq/headlessmc/api/classloading'
    exports 'io/github/headlesshq/headlessmc/api/command'
    exports 'io/github/headlesshq/headlessmc/api/command/line'
    exports 'io/github/headlesshq/headlessmc/api/command/impl'
    exports 'io/github/headlesshq/headlessmc/api/util'
    exports 'io/github/headlesshq/headlessmc/api/exit'
    exports 'io/github/headlesshq/headlessmc/runtime'
    exports 'io/github/headlesshq/headlessmc/runtime/commands'

    requires 'java.logging'
}

shadowJar {
    from genModuleInfo
    excludes.remove("module-info.class")
}
