How to add a linked source folder from a remote machine in Android Studio?

时间:2015-07-31 20:51:39

标签: android android-studio

Trying to follow this post How to add a linked source folder in Android Studio?,

I tried

sourceSets {
    main.java.srcDirs += 'src/main/\\\\10.11.12.13\\me\\workspace\\myapp\\src'
}

However it does not display the source folder. If I do

sourceSets {
    main.java.srcDirs += '\\\\10.11.12.13\\me\\workspace\\myapp\\src'
}

Then the sources are visible but outside my project app tree. How to get them inside?

1 个答案:

答案 0 :(得分:0)

这对我有用:

在app / main / build.gradle中

android {
...
    sourceSets {
        main.java.srcDirs += '\\\\\\10.11.12.13\\me\\workspace\\myapp\\src'
    }
}