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

  • Home
  • SEARCH
  • 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 8915505
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T04:59:16+00:00 2026-06-15T04:59:16+00:00

I want to write addtional texts to the Java resource files (combine two .java

  • 0

I want to write addtional texts to the Java resource files (combine two .java files to one). And I write a python script to do so.

I also want to automate the steps (combines files, compile, package) using Maven. I am a newbie to Maven, I found that exec-maven-plugin could run the python script.

I tried to set<phase>process-resources</phase> to try to make it start before compile, but Eclipse complained that Plugin execution not covered by lifecycle configuration: org.codehaus.mojo:exec-maven-plugin:1.2.1:exec
(execution: default, phase: process-resources)

below is my pom of the exec-maven-plugin:

  <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>exec-maven-plugin</artifactId>
        <version>1.2.1</version>
        <executions>
            <execution>
                <phase>process-resources</phase> <!-- Eclipse complains an error here -->
                <goals>
                    <goal>exec</goal>
                </goals>
            </execution>
        </executions>
        <configuration>
            <executable>python</executable>
            <workingDirectory>src/main/python</workingDirectory>
            <arguments>
                <argument>combine.py</argument>
            </arguments> 
        </configuration>
    </plugin>

Anyone know that how could I implement this purpose? Thanks a lot.

  • 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-15T04:59:17+00:00Added an answer on June 15, 2026 at 4:59 am

    This is the Eclipse M2e plugin trick. Sachin Shekhar R is right, but the answer is not clear enough for newbies like me. Here comes my understanding:

    See http://wiki.eclipse.org/M2E_plugin_execution_not_covered.
    There are two methods to do so in Eclipse M2e.

    1. use the code listed in Sachin Shekhar R‘s answer. Notice that this piece of code must under <pluginManagement><plugins> and <pluginManagement> must be inside <plugins>. sample code:

      <build>
      <plugins>
                  <plugin>
                     <!-- plugins here-->
                  </plugin>
      </plugins>
      <pluginManagement>
          <plugins>
              <plugin>
                  <groupId>org.eclipse.m2e</groupId>
                  <artifactId>lifecycle-mapping</artifactId>
                  <version>1.0.0</version>
                  <configuration>
                      <lifecycleMappingMetadata>
                          <pluginExecutions>
                              <pluginExecution>
                                  <pluginExecutionFilter>
                                      <groupId>org.codehaus.mojo</groupId>
                                      <artifactId>exec-maven-plugin</artifactId>
                                      <versionRange>[1.2.1,)</versionRange>
                                      <goals>
                                          <goal>exec</goal>
                                      </goals>
                                  </pluginExecutionFilter>
                                  <action>
                                      <ignore/>
                                  </action>
                              </pluginExecution>
                          </pluginExecutions>
                      </lifecycleMappingMetadata>
                  </configuration>
              </plugin>
          </plugins>
      </pluginManagement>
      </build>
      

      This only works in the project.

    2. use the “Quick Fix” feature of the Eclipse M2e plugin. It exists after version 1.0. Find the error in Problems tab. Right click on it, select “Quick Fix”. There would be a Quick Fix window popping up, select the second option Mark goal exec as ignored in Eclipse build in Eclipse references (experimental).
      This method would write above code between <lifecycleMappingMetadata> into workspace profile of lifecyclemapping into workspace/.metadata/.plugins/org.eclipse.m2e.core/lifecycle-mapping-metadata.xml
      This works in the entire workspace

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

Sidebar

Related Questions

Hello I want write my own desktop sharing application in Java. The application should
I want to write a batch script statement where: FINDSTR has to check for
I want to write a program to contact a PHP script online, and show
I want write a simple query which will fetch data from a table (which
I want write a little code analyzer which parses nested structures and translates into
I want to write a program in Prolog that confirms if a b-tree of
I want to write <a href=product.php?id=5> as product/5.I am not talking about user to
I want to write a procedure to perform a delete for the following i
I want to write a class with three int values in them and manipulate
I want to write a file on my iPhone app. My file is in

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.