title: Add classpath to spring boot in Intellij
body: <p>Usually spring boot would restart when files in the classpath change. But when I ran spring boot in intellij and changed some contents in <code>src/main/resources/static/templates/index.html</code>, I found that spring boot didn't restart. After debugging for a while, I found that the path I just mentioned was not part of classpath. The related classpaths are the corresponding output paths.</p>
  
  <pre><code>build/classes/main/
  build/resources/main/
  </code></pre>
  
  <p>So my question is, can I add <code>src/main</code> to classpath in intellij so spring boot will auto restart the server when changes are made? It might not be hard to do this in commandline, but I didn't find a way to achieve this in Intellij.</p>