react-native 打包报错

关于学习过程中打包android apk时的报错

在项目中新增了第三方原生组件react-native-image-crop-picker时,本地调试正常,打包测试时报错!

// 报错信息如下
Could not resolve all files for configuration ':jcore-react-native:lintClassPath'.
> Could not download groovy-all.jar (org.codehaus.groovy:groovy-all:2.4.15)
   > Could not get resource 'https://jcenter.bintray.com/org/codehaus/groovy/groovy-all/2.4.15/groovy-all-2.4.15.jar'.
      > Could not GET 'https://jcenter.bintray.com/org/codehaus/groovy/groovy-all/2.4.15/groovy-all-2.4.15.jar'.
         > Remote host closed connection during handshake
> Could not download trove4j.jar (org.jetbrains.trove4j:trove4j:20160824)
   > Could not get resource 'https://jcenter.bintray.com/org/jetbrains/trove4j/trove4j/20160824/trove4j-20160824.jar'.
      > Could not GET 'https://jcenter.bintray.com/org/jetbrains/trove4j/trove4j/20160824/trove4j-20160824.jar'.
         > Connection reset

各种查阅后,得到结果如下:猜测应该是网络问题,翻墙?导致无法获取jar包

//在android build.gradle中将 
google()
jcenter()
//替换为
maven { url 'https://maven.aliyun.com/repository/google'}
maven { url 'https://maven.aliyun.com/repository/jcenter'}
maven { url 'http://maven.aliyun.com/nexus/content/groups/public'}

猜你喜欢

转载自blog.csdn.net/weixin_33895475/article/details/90867616