您好,我想将ant脚本转换为gradle。有自动转换的工具吗?
我在尝试 Android Studio 时发现,如果您使用 ant build 导入一个项目,它会询问您是否将其转换为 gradle。即使您单击"is",它也会生成一个包含
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {`
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:0.8.+'
}
}
allprojects {
repositories {
mavenCentral()
}
}
有人知道我在哪里可以找到转换后的 gradle 脚本,或者任何其他方法吗?
最佳答案
关于你的问题
Does anyone know where I can find the converted gradle script,or any other method to do so?
Gradle 创建两个 build.gradle
文件:一个在项目级别,一个在项目目录。 应用程序/源
。第二个可能包含您一直在寻找的指令。
你可能想看看 more detailed description of the Android Studio files .
如果你来这里是为了将一个通用的ant转换成一个gradle脚本
从 AndroidStudio 1.3 开始,它是开箱即用的。
关于android - Android Studio 可以将 ant 构建脚本转换为 gradle 构建脚本吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23098407/