What is the target folder, what is mvnw and mvnw.cmd file and what is src folder?
Asked
Active
Viewed 376 times
2 Answers
2
That is the default structure for a Maven project and this structure is also used as a defacto standard (Gradle uses it as well for instance).
The
target
directory is used to house all output of the build.The
src
directory contains all of the source material for building the project, its site and so on. It contains a subdirectory for each type:main
for the main build artefact,test
for the unit test code and resources,site
and so on.
Source: The Maven guide (see link above).
The mvnw
script and .mvnw
directory (currently hidden) is for the Maven Wrapper, which makes it easier to use Maven. It will automatically download the correct version of Maven before building the application.
Related questions:

M. Deinum
- 115,695
- 22
- 220
- 224