I use Intellij Idea.
Java-classes use .txt
files which are placed in folder where .java
files are situated.
I created .jar
file with maven and pom.xml. But there are no .txt
in .jar
file.
How to add them there?
UPDATED:
I have such structure src/main/java/Project-name/
for .java
files. And src/main/resources/
for .txt
files. Within .java
files I access files as ../../resources/filename.xml
and all works fine. But .jar-files created with maven says:
Unable to open "../../resources/filename.xml"
How correctly should I declare filenames?