-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
m2e plugin "looses" resources after changes pom.xml - using 2.4.100.20230827-1557 #1585
Comments
m2e does not copy anything, maven-resource-plugin does: |
I think this is a duplicate of #1511 |
Right now the workaround we're having is to have a launcher which will touch all resource files. So basically after building, we'll then need to launch this and as now eclipse detects the files as modified, they will get copied over into the resources again. |
I've downgraded the version to 2.1.2, and it is as normal as tarioch said. |
my own workaround is to have a Maven launcher in Eclipse running "resources:resources" each time before launching my software. This is not ideal. |
I think so as well. I'll close this as duplicate of #1511. |
Duplicate of #1511 |
I am experiencing a problem with the
m2e
plugin inEclipse
. After making changes to mypom.xml
, specificallyadding
orremoving
adependency
, the project'ssrc/main/resources
andsrc/test/resources
files are not automatically copied to thetarget
directory. However, when Iright-click
on the project and choose"Maven" > "Update Project..."
the resources are properly copied to the target directory. This seems to be an issue with the automatic resource copying mechanism ofm2e
.Version Information:
Eclipse Version: [2023-09 (4.29.0), Build id: 20230907-1323]
m2e Plugin Version: [Maven Integration for Eclipse 2.4.100.20230827-1557]
Maven Version: [3.9.4]
Operating System: [MacOS Monterey 12.7]
Steps to Reproduce:
Open an Eclipse Maven project.
Edit the
pom.xml
byadding or removing
adependency
.Observe that the
src/main/resources
andsrc/test/resources
files are not copied to thetarget
directory.Right-click on the project, choose
"Maven" > "Update Project..."
and observe that the resources are now copied to the target directory.Expected Behavior:
I expect that after modifying the pom.xml, the resources in
src/main/resources
andsrc/test/resources
should be automatically copied to thetarget
directory without the need to manually trigger "Update Project."Actual Behavior:
The resources in
src/main/resources
andsrc/test/resources
are not copied to the target directory automatically after modifying the pom.xml. Manual intervention by right-clicking on the project and updating it is required.Additional Information:
There are no error messages or warnings in the Eclipse IDE.
I have verified that the Maven build process is configured correctly in the pom.xml.
This issue is affecting my workflow and productivity as it requires manual intervention each time I make a change to the pom.xml.
Possible Solutions:
I am not sure about the exact cause of this issue, but it seems like there might be an issue with the m2e plugin's automatic resource copying mechanism. It might be worth investigating the plugin's behavior in response to changes in the pom.xml.
Notes:
I have tested this issue on different projects and the problem persists.
The text was updated successfully, but these errors were encountered: