title: How to nest modules in Android Studio
body: <p>I am trying to build a project with the following structure. It is an app that uses a library project using another library (Google Volley).</p>
  
  <pre><code>- MainProject
  |-- ModuleProject
      |-- SubmoduleProject
  </code></pre>
  
  <p>ModuleProject/build.gradle</p>
  
  <pre><code>buildscript {
      repositories {
          mavenCentral()
      }
  
      dependencies {
          classpath 'com.android.tools.build:gradle:0.9.+'
      }
  }
  
  apply plugin: 'android-library'
  
  dependencies {
      compile project(':SubmoduleProject')
  }
  </code></pre>
  
  <p>ModuleProject/settings.gradle</p>
  
  <pre><code>include ':SubmoduleProject'
  </code></pre>
  
  <p>Android studio throws the following error:</p>
  
  <pre><code>Project with path ':SubmoduleProject' could not be found in project ':ModuleProject'
  </code></pre>
  
  <p>How can I build my project with nested libraries?</p>