package dev.meloda.fast

import org.gradle.api.Project
import org.gradle.api.artifacts.VersionCatalog
import org.gradle.api.artifacts.VersionCatalogsExtension
import org.gradle.kotlin.dsl.getByType

val Project.libs
    get(): VersionCatalog = extensions.getByType<VersionCatalogsExtension>().named("libs")


fun Project.getVersionInt(alias: String): Int {
    return libs.findVersion(alias).get().requiredVersion.toInt()
}
