簡體   English   中英

從eclipse導入項目到android

[英]importing project from eclipse to android

我正在將eclipse的項目導入到android studio中,並且在索引完索引后執行操作時給我android plug in id not found當我單擊下面的文件時,打開文件的選項為我打開了應用插件: com.android.application

dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
compile project(':gesture-imageview')
}

android {
compileSdkVersion 22
buildToolsVersion "19.1.0"

compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_7
    targetCompatibility JavaVersion.VERSION_1_7
}

sourceSets {
    main {
        manifest.srcFile 'AndroidManifest.xml'
        java.srcDirs = ['src']
        resources.srcDirs = ['src']
        aidl.srcDirs = ['src']
        renderscript.srcDirs = ['src']
        res.srcDirs = ['res']
        assets.srcDirs = ['assets']
    }

    // Move the tests to tests/java, tests/res, etc...
    instrumentTest.setRoot('tests')

    // Move the build types to build-types/<type>
    // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
    // This moves them out of them default location under src/<type>/... which would
    // conflict with src/ being used by the main source set.
    // Adding new build types or product flavors should be accompanied
    // by a similar customization.
    debug.setRoot('build-types/debug')
    release.setRoot('build-types/release')
}

}

嘗試在buildToolsVersion "19.1.0"下面的android {...}buildToolsVersion "19.1.0"

defaultConfig {
    applicationId 'com.your.app.id'
    minSdkVersion 15 //your minsdk
    targetSdkVersion 22 /your targetsdk
    versionCode 1
    versionName "1.0"
}

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM