More than one file was found with OS independent path 'META-INF/rxjava.properties

2019-04-22 13:48:05

  之前落下了android新出的很多常用的类库(ok3,rxjava,retrofit)今天刚好有时间,就一个一个学习下,虽然源码看着后面,忘着前面,不过现在好在都会用了噻

添加需要的类库

 compile 'com.squareup.retrofit2:retrofit:2.0.2'

    compile 'com.squareup.retrofit2:converter-gson:2.0.2'

    compile 'com.squareup.okhttp3:okhttp:3.1.2'

    compile 'com.squareup.okio:okio:1.7.0'

    compile 'com.squareup.retrofit2:adapter-rxjava:2.0.2'

   compile 'com.squareup.retrofit2:adapter-rxjava2:2.3.0'

在retrofit结合rxjava2的过程中,遇到了一个问题,

特记录一下:

More than one file was found with OS independent path 'META-INF/rxjava.properties

解决方式如下:

在app下的build.gradle里面的defaultConfig里面添加:

 defaultConfig {

       packagingOptions {

            exclude 'META-INF/rxjava.properties'

        }

    }


  • 2019-10-27 11:02:10

    mac不要输入sudo,免密设置

    mac有时候使用终端进行操作,会让输入sudo 并且要输入命令,这要很啰嗦,浪费时间,我们得想办法去掉。

  • 2019-10-27 11:08:11

    Mac系统移到废纸篓的快捷键是什么

    用Windows键盘上的delete键和del键都不能删除文件,那么在Mac系统移到废纸篓的快捷键是什么?答:在移到废纸篓的快捷键组合就是Command + delete,可以将文件删除到废纸篓。清空废纸篓的快捷键是 Command + shift + delete​。

  • 2019-10-29 11:30:12

    Vue路由的$router.back(-1)回退时如何判断有没有上一个路由

    这个函数是这样的,判断当前页面的历史记录是不是小于等于1,如果小于等于1,说明这个页面没有可以返回的上一页,如果没有可以返回的上一页,就给地址栏加上一个goindex=true的参数,这样你从这个页面在往下一个页面跳转在返回,这个参数就一直加上的