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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T16:58:48+00:00 2026-05-23T16:58:48+00:00

I have a maven project – it is a plugin for jenkins. It’s parent

  • 0

I have a maven project – it is a plugin for jenkins. It’s parent should be a:

<parent>
  <groupId>org.jenkins-ci.plugins</groupId>
  <artifactId>plugin</artifactId>
  <version>1.414</version>
</parent>

But at the same time this plugin can be also used for hudson, without changing any line of code. But the parent project for it should be:

<parent>
  <groupId>org.jvnet.hudson.plugins</groupId>
  <artifactId>hudson-plugin-parent</artifactId>
  <version>2.0.1</version>
</parent>

Can I specify 2 different profiles for that and use them to build plugin for jenkins or hudson accordingly? So that I call something like that:

mvn package -P jenkins

or

mvn package -P hudson

I have tried to specify properties in profiles, but those are not replaced by their values inside the <parent> tag. So is there any other possibility to build plugin for both, but with as much as possible common code and files?

Added: So, if I cannot do that, what should I do then? How to refactor? What the new structure should be?

  • 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-23T16:58:49+00:00Added an answer on May 23, 2026 at 4:58 pm

    Currently we decided to stick with 1 repository and 2 separate pom.xml files, giving maven key which pom.xml use to build the project.

    mvn package -f pom-jenkins.xml
    mvn package -f pom-hudson.xml
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Currently, I have a Maven project which inherits from a parent pom defining two
I have a maven multimodule project. What the best practices for creating groupId? Can
We have a multi-module maven project that uses a profile that defines a buildnumber-maven-plugin
I have maven parent project with several child projects. On deploy I want to
I have a maven project which uses the shade plugin to create a jar
I have a maven project which is build and tested in Jenkins. On my
I have a maven project where I want to use the Cargo-Maven-Plugin (1.1.1) to
I have a Maven project that uses the jaxb2-maven-plugin to compile some xsd files.
I have a maven project with the following POM snippet: <modelVersion>4.0.0</modelVersion> <artifactId>Foo-Deploy</artifactId> <name>Foo-Deploy</name> <packaging>pom</packaging>
We have a maven project where I use a checkstyle plugin in the build

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.