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 3613036
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T22:04:26+00:00 2026-05-18T22:04:26+00:00

i have huge project that contains around 200 jars, when i prepare release maven

  • 0

i have huge project that contains around 200 jars, when i prepare release maven prepare for all jars but for sure there are jars that has not been modified since last build so is there any way to check if jar has been modified since last build from scm? and exclude them?

i dont want to relase jars (more than 200) individually.

for example: i want to make relase for parent but i dont want to relase jar4 that has not been modified

-Parent

---------Module1

----------------jar1*

----------------jar2*

---------Module2

----------------jar3*

----------------jar4   
  • 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-05-18T22:04:27+00:00Added an answer on May 18, 2026 at 10:04 pm

    for example: i want to make relase for parent but i dont want to relase jar4 that has not been modified

    The syntax for this is

    mvn -pl Module1,Module2/jar3 <your maven goals here>
    

    (in this case you want to build all of Module1 and just jar3 of Module2)

    Now the tricky part is how to assemble the parameter to -pl. I am pretty sure there is no maven way to do that, so you will probably have to write a shell script (or Ruby, Groovy, PERL python etc. script) that does that for you.

    Basically, what your script must do:

    • look for all maven project directories (directories that contain a pom.xml) in the given directory, sort them in reverse (deepest paths first)
    • find all changed files in the entire hierarchy (using svn, cvs or whatever calls)
    • map each changed file to one of the projects (by comparing paths), collect all matched projects in a list
    • Now optimize the list by doing some parent/child optimization (if all children of a given parent are present, remove the children and add the parent). Do this repeatedly until you reach the root hierarchy.
    • From the remaining list, extract the relative paths, join them with a comma and start your maven process using that value for the -pl parameter.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just been handed a huge project for an application that must run
We have a project that was implemented in linq to sql and is being
I have a project that I wrote in PHP/symfony that uses 45 tables. I'm
I have a question about database architecture. We are building a CMS. There are
I have three big header files (4.5MB and more), with huge static arrays inside.
I have a table of People, and a table of Service Tickets. Service Tickets
We currently have 3 devs with, some, conflicting styles and I'm looking for a
https://stackoverflow.com/questions/149698/what-is-a-good-mfc-starting-book A lot of the upvoted comments claim there are much better alternatives. I'd
I was reading the book Git Internals and was awestruck by its simplicity. So

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.