Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8278497
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T09:02:15+00:00 2026-06-08T09:02:15+00:00

Maven’s multi-modules plugin doc states clearly: Modules are regular Maven projects which must be

  • 0

Maven’s multi-modules plugin doc states clearly:

Modules are regular Maven projects which must be located under a subdirectory so the parent project can retrieve them easily.

The thing is I don’t want to locate them under a subdirectory. I just want to point to some file path which can be used in order to compile dependencies. (Highlighted, since this is the question actually).

The reason I want it is simple: I just don’t want to mess two completely different paradigms – maven modules and git submodules – in one folder. Moreover, I don’t want to have any kind of git dependencies in the project.

Solution number 0, i.e. to create simlinks and to put them to .gitignore does not count 😉

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T09:02:17+00:00Added an answer on June 8, 2026 at 9:02 am

    The best solution is to create the directory structure within a single git repository and don’t use submodules in Git. This will result in a structure like this:

    root (pom.xml)
      +-- module1 (pom.xml)
             +-- src/main/java
             +-- src/test/java
      +-- module2 (pom.xml)
             +-- src/main/java
             +-- src/test/java
      +-- module3 (pom.xml)
             +-- src/main/java
             +-- src/test/java
    

    The above structure will be put under Git version control with the root folder which comprises of the sub modules as well. Not submodules etc. in Git.
    If you have dependencies in this scenario you have to use module dependencies which are the best practice in Maven.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Env: Maven 2.2.1 I have two java projects under svn (projectA, projectB). My maven
Using Maven war plugin, I generate WAR which includes following directory: META-INF -- maven
dbunit-maven-plugin 1.0-SNAPSHOT release supported expressing multiple src files under sources tag, how do you
I have a maven multi-module pom which builds a war. I want to declare
Maven Jetty plugin is very nice (I'm using version 6.1.26). The only annoying thing
Maven's assembly plugin enables the creation of a big jar including all dependencies with
The Maven Buildnumber plugin doesn't appear to work with GIT yet. Is there a
The maven configuration mentioned in the Usage section of the Natural Docs Maven Plugin
maven-clean-plugin removes target folder by default, but I would also like it to remove
Which maven repository has the latest hibernate core 3.5? I have repository.jboss.com/maven2 and it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.