ghedeon06/20/2018, 5:47 PM
if you can keep it flat.
gildor06/21/2018, 5:13 AM
In pure Kotlin projects, the recommended directory structure is to follow the package structure with the common root package omitted (e.g. if all the code in the project is in the “org.example.kotlin” package and its subpackages, files with the “org.example.kotlin” package should be placed directly under the source root, and files in “org.example.kotlin.foo.bar” should be in the “foo/bar” subdirectory of the source root).https://kotlinlang.org/docs/reference/coding-conventions.html
ghedeon06/21/2018, 9:06 AM
support. Except for libraries. There is no
for libraries and I'm not sure how to solve it yet.
gildor06/21/2018, 9:08 AM
dictated by the gradle pluginnot dictated, but gradle plugin has default layout and not only on Android, same with Java projects
considering build variants and flavorsexactly, default layout is created to allow easily add some code to another source set and this source set can be used by particular build type or flavor, but if you don’t use it, I don’t think that there is any problems with it
arekolek06/21/2018, 9:18 AM
I stopped using packages for my appsdo you use modules though? or is it all in the same module in the same package
gildor06/21/2018, 9:24 AM
ghedeon06/21/2018, 9:28 AM
to “org.example.kotlin.foo.bar”. So, the source path is
gildor06/21/2018, 9:29 AM
ghedeon06/21/2018, 9:31 AM
gildor06/21/2018, 9:32 AM
ghedeon06/21/2018, 9:33 AM
, if you want to get rid of nested folders in a library, you have to explicitly specify the desired package for your files (ex:
). Which is not required for the app module.
>dictated by the gradle plugin
not dictated, but gradle plugin has default layouttautology
. Probably depends on the project scale, but imho it's unnecessary.
gildor06/21/2018, 10:17 AM
explicitly specify the desired package for your files (ex:Yes, it’s true, you have to specify package. But for library you can just use any package, like)