Android开发者noobie在这里。
我获得了最新的iosched 2013源代码并解决了大部分问题并相应地编辑了Gradle文件(至少我认为我在正确的轨道上)。
我现在可以在AVD中启动该应用。主要通过以下方式解决:
当我转到Build > Clean Project
时,会显示Gradle invocation completeed succesfully
但Android Studio中的下划线有下划线:
compile 'com.google.android.apps.dashclock:dashclock-api:+'
compile 'com.google.code.gson:gson:2.+'
exclude group: 'org.apache.httpcomponents', module: 'httpclient'
compile 'com.google.apis:google-api-services-plus:+'
Gradle来源:
/*
* Copyright 2013 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
apply plugin: 'android'
repositories {
mavenCentral()
}
dependencies {
compile 'com.google.android.gms:play-services:3.+'
compile 'com.android.support:appcompat-v7:19.1.0'
compile 'com.google.android.apps.dashclock:dashclock-api:+' // underlined from dashclock:dashclock-api:+
compile 'com.google.code.gson:gson:2.+' // underlined from gson:gson:2.+'
compile('com.google.api-client:google-api-client:1.+') {
exclude group: 'xpp3', module: 'shared'
exclude group: 'org.apache.httpcomponents', module: 'httpclient' // underlined from httpcomponents', module: 'httpclient'
exclude group: 'junit', module: 'junit'
exclude group: 'com.google.android', module: 'android'
}
compile 'com.google.api-client:google-api-client-android:1.17.+'
compile 'com.google.apis:google-api-services-plus:+' // underlined from apis:google-api-services-plus:+'
compile fileTree(dir: 'libs', include: '*.jar')
}
android {
compileSdkVersion 19
buildToolsVersion "19.0.0"
defaultConfig {
minSdkVersion 10
targetSdkVersion 19
}
}
非常感谢帮助。
感谢 - 你!
修改
添加了我的意思的截图
答案 0 :(得分:1)
那些警告(不是错误)完全没问题。事实上,我建议你关掉这个警告,因为90%的时间都是误报。
要关闭警告,请转到File -> Settings -> Inspections
,然后搜索“拼写”。取消结果,然后点击Ok
。警告将消失。
底线:如果没有其他错误,您应该能够构建运行应用程序。这些警告不应该阻止这种情况。