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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T23:49:39+00:00 2026-05-12T23:49:39+00:00

I have a Maven project that is a child project. It has many sibling

  • 0

I have a Maven project that is a child project. It has many sibling projects and the job of this project is to get resources from the siblings and package them in a zip file using the antrun plugin.

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <parent>
        <artifactId>SystemOfRegistries</artifactId>
        <groupId>someGroup</groupId>
        <version>0.0.1-SNAPSHOT</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>someGroup</groupId>
    <artifactId>deploy-data</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>pom</packaging>
    <build>
        <plugins>
            <plugin>
                <artifactId>maven-antrun-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <configuration>
                            <tasks>
                                <!--
                                    Place any Ant task here. You can add anything you can add
                                    between <target> and </target> in a build.xml.
                                -->
                                <zip destfile="${project.build.directory}/${build.finalName}.zip"
                                    whenempty="fail">
                                    <zipfileset dir="${project.parent.basedir}/build/AG" prefix="ag"/>
                                </zip>
                            </tasks>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
</project>

This worked fine for building the zip. However, the problem is that the zip is not the artifact of the build. And, thus there is no link in Hudson to download it.

I would either like to figure out how to get Hudson to recognize this as an artifact of Maven, or get Maven to realize that the ZIP is the artifact. (I used to have packaging element missing and then I would get an unwanted JAR as artifact).

  • 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-12T23:49:39+00:00Added an answer on May 12, 2026 at 11:49 pm

    You can use builder-helper-maven-plugin

    <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <version>1.3</version>
        <executions>
            <execution>
                <id>attach-artifacts</id>
                <phase>package</phase>
                <goals>
                    <goal>attach-artifact</goal>
                </goals>
                <configuration>
                    <artifacts>
                        <artifact>
                            <file>${project.build.directory}/${build.finalName}.zip</file>
                            <type>zip</type>
                        </artifact>
                    </artifacts>
                </configuration>
            </execution>
        </executions>
    </plugin>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a few maven projects that inherit from eachother. Our persistence layer project's
I have a maven project that has a set of library dependancies that are
I have a maven project that has both code and documentation (pdf files). When
I have a single maven project that has multiple main classes. I want to
I have maven parent project with several child projects. On deploy I want to
I'm new to Maven. I have a multi-module maven 2 project that has the
For example, I have 2 Maven projects. One is project-parent. The other is project-child.
I have a maven multi-module project (boy, I've written that opening way too many
I have a maven project that produces many artifacts. Of course it is kind
I have a Maven project that has always worked fine in Netbeans, but upgrading

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.