我想用底部栏 https://github.com/roughike/BottomBar我的项目中的库。当我添加正确的gradle
命令在build.gradle
文件和sync
,我收到此错误:
Failed to resolve: com.roughike:bottom-bar:2.0
我查了很多原因。解决方案是使用 jcenter(),但这在我的国家/地区无法访问,并且同步最多持续 1 小时,有时甚至持续 2 小时。所以我改用maven。
这种情况下如何使用库主页推荐的maven命令呢?
我应该把下面的代码放在哪里?
<dependency>
<groupId>com.roughike</groupId>
<artifactId>bottom-bar</artifactId>
<version>2.+</version>
<type>pom</type>
</dependency>
Gradle
dependencies {
compile 'com.roughike:bottom-bar:2.+'
}
如果错误同步 gradle 运行代理(Host=127.0.0.1 , proxyPort=8580
)并在cmd中输入此命令
gradlew -Dhttps.proxyHost=127.0.0.1 -Dhttps.proxyPort=8580
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)