Search code examples
intellij-ideaintellij-14

How to attach source code for debugging in jar intellij?


I wanted to add source code to my custom jar.

I tried adding "src" folder to jar by selecting

** File->Project Structure->Artifect->output layout->"+"**

. But It did not work for me.

I even tried adding "src" folder by clicking "CTRL+click"->Attach source. It says attaching but nothing happens.

Is there any way to add source code while creation of jar?

I am using Intelij-Idea 14.1.4


Solution

  • There was a bug in Android studio 1.2 because of that source attachment was not working. It is fixed in 1.3. For go to this link https://code.google.com/p/android/issues/detail?id=181416

    To fix this update your Android Studio