Automating synchronization when developping several libraries and projects at the same time

前端 未结 1 777
感动是毒
感动是毒 2020-12-22 05:49

I want incremental updates of my library files to immediately be applied in all of my projects using them, without having to perform an extra step every time for every one o

相关标签:
1条回答
  • 2020-12-22 06:35

    With the library folder in the LIBS_DIR environment variable:

    // settings.gradle
    include ':app', ':lib1', ':lib2'
    project(':lib1').projectDir = new File(System.getenv('LIBS_DIR'), 'lib1')
    project(':lib2').projectDir = new File(System.getenv('LIBS_DIR'), 'lib2')
    

    ‏‏‎

    // build.gradle
    ...
    dependencies {
        compile project(path: ':lib1')
        compile project(path: ':lib2')
    }
    
    0 讨论(0)
提交回复
热议问题